equal
deleted
inserted
replaced
218 UIImage *result = UIGraphicsGetImageFromCurrentImageContext(); |
218 UIImage *result = UIGraphicsGetImageFromCurrentImageContext(); |
219 UIGraphicsEndImageContext(); |
219 UIGraphicsEndImageContext(); |
220 return result; |
220 return result; |
221 } |
221 } |
222 |
222 |
|
223 +(UIImage *)whiteImage:(CGSize) ofSize { |
|
224 // white rounded rectangle as background image for previewButton |
|
225 UIGraphicsBeginImageContext(ofSize); |
|
226 CGContextRef context = UIGraphicsGetCurrentContext(); |
|
227 UIGraphicsPushContext(context); |
|
228 |
|
229 CGContextSetRGBFillColor(context, 1.0, 1.0, 1.0, 1.0); |
|
230 CGContextFillRect(context,CGRectMake(0,0,ofSize.width,ofSize.height)); |
|
231 |
|
232 UIGraphicsPopContext(); |
|
233 UIImage *bkgImg = UIGraphicsGetImageFromCurrentImageContext(); |
|
234 UIGraphicsEndImageContext(); |
|
235 return bkgImg; |
|
236 } |
|
237 |
223 @end |
238 @end |