[categories] [index] [all (531)] [latest]
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
@compatibility_alias UIColor NSColor;
#endif
[[NSUserDefaults standardUserDefaults] setObject:@YES forKey:@"UIUseLegacyUI"]
https://twitter.com/stroughtonsmith/status/384679231730761728
- (UIImage *)image {
UIGraphicsBeginImageContext(self.frame.size);
[self.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *img = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return img;
}
- (void)applicationDidFinishLaunching:(UIApplication *)application {
application.statusBarHidden = YES;
// ...
}
[UIApplication sharedApplication].idleTimerDisabled = YES;
#ifdef DEBUG
[NSTimer scheduledTimerWithTimeInterval:1.0
target:application
selector:@selector(_performMemoryWarning)
userInfo:nil
repeats:YES];
#endif
po [UIView recursiveDescription]
results:
<UIView: 0x4b4d3d0; frame = (0 20; 320 460); (...)
| <MyView: 0x4b4b800; frame = (20 20; 237 243); (...)
| | <UIRoundedRectButton: 0x4b4e790; (...)
| | | <UIButtonLabel: 0x4b4f190; (...)