#import <UIKit/UIKit.h>@interface BlueBadge : UIView { NSInteger count;}@property (nonatomic) NSInteger count;- (void)drawWithCount:(NSInteger)i;@end#import "BlueBadge.h"@implementation BlueBadge@synthesize count;- (id)initWithFrame:(CGRect)frame { if (self = [super initWithFrame:fra Read More
posted @ 2010-02-08 15:33
javawebsoa
Views(250)
Comments(0)
Diggs(0)
定位某行的错误#define ZNLog(s,...) [ZNLog file:__FILE__ function: (char *)__FUNCTION__ lineNumber:__LINE__ format:(s),##__VA_ARGS__]#import <Foundation/Foundation.h>@interface ZNLog : NSObject {}+(void)file:(char*)sourceFile function:(char*)functionName lineNumber:(int)lineNumber format:(NSString*)fo Read More
posted @ 2010-02-08 15:29
javawebsoa
Views(182)
Comments(0)
Diggs(0)
RT:-(float)getTotalDiskSpaceInBytes { float totalSpace = 0.0f; NSError *error = nil; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSDictionary *dictionary = [[NSFileManager defaultManager] attributesOfFileSystemForPath:[paths lastObject] e... Read More
posted @ 2010-02-08 11:57
javawebsoa
Views(250)
Comments(0)
Diggs(0)
1.Combine two UIImages-合成To add two UIImages together you need to make use of Graphics Context.- (UIImage *)addImage:(UIImage *)image1 toImage:(UIImage *)image2 { UIGraphicsBeginImageContext(image1.size); // Draw image1 [image1 drawInRect:CGRectMake(0, 0, image1.size.width, image1.size.height)... Read More
posted @ 2010-02-08 11:11
javawebsoa
Views(236)
Comments(0)
Diggs(0)

浙公网安备 33010602011771号