ȥå   Խ ʬ Хåå ź ʣ ̾ѹ   ñ측 ǽ   إ   ǽRSS

Objective-C

Last-modified: 2013-04-13 () 09:31:59 (1684d)
Top / Objective-C

TIPS

ߥ졼ȼµդѥʬˡ

#if TARGET_IPHONE_SIMULATOR
	NSString *hello = @"Hello, iOS simulator!";
#else
	NSString *hello = @"Hello, iOS device!";
#endif

iPhoneiPadǽʬˡ

if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
 	NSLog(@"iPadν");
} else {
 	NSLog(@"iPhoneν");
}

Ѹ: iPhoneiPadȽȽꤷʬˡ |