This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[UIView transitionFromView:self.view toView:listsViewController.view | |
duration:1 options:UIViewAnimationOptionTransitionFlipFromRight | |
completion:^(BOOL finished) { | |
[[UIApplication sharedApplication].delegate window].rootViewController = listsViewController; | |
}]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://placehold.it/120x100 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[self transitionFromViewController: toViewController: duration: options: animations: completion]; | |
self.view.transform = xxx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
number % 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . ! -wholename '*Vendor*' -name "*.h" -exec cat {} \; | wc -l |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSSortDescriptor *sortNameDescriptor = [[NSSortDescriptor alloc] initWithKey:@"firstName" ascending:YES]; | |
[company.workers sortedArrayUsingDescriptors:@[sortNameDescriptor]]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSString *fontName = self.label.font.fontName; | |
CGFloat fontSize = self.label.font.pointSize; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSLog(@"%@", [UIFont fontNamesForFamilyName:@"Helvetica"]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define SCREEN_WIDTH ([UIScreen mainScreen].bounds.size.width) | |
#define SCREEN_HEIGHT ([UIScreen mainScreen].bounds.size.height) | |
#define IOS_VERSION [[[UIDevice currentDevice] systemVersion] floatValue] | |
#define CurrentSystemVersion ([[UIDevice currentDevice] systemVersion]) | |
#define CurrentLanguage ([[NSLocale preferredLanguages] objectAtIndex:0]) | |
//use dlog to print while in debug model | |
#ifdef DEBUG | |
# define DLog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, 1 * NSEC_PER_SEC), dispatch_get_current_queue(), ^{ | |
//// will be executed after 1 second | |
}); |