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
@interface ACViewController : UIViewController | |
{ | |
UIViewController* _childViewController; | |
UIScrollView* _scrollView; | |
UIButton* _button; | |
int _counter; | |
NSString* _text; | |
CGPoint _lastScrollViewPosition; | |
} |
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
#import "ACSingleton.h" | |
@implementation ACSingleton | |
#pragma mark - | |
#pragma mark Singleton Pattern | |
static ACSingleton* _sharedInstance; | |
static dispatch_once_t _instanceFlag; | |
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
#pragma mark - | |
#pragma mark Controller Lifecycle | |
// Called once the view controller is initialized in your code | |
- (id)init | |
{ | |
self = [super init]; | |
if (self) { | |
// Initialize iVars that live and die with your controller | |
_myList = [[NSMutableArray alloc] initWithCapacity:5]; |
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
#import "ACSingleton.h" | |
@implementation ACSingleton | |
#pragma mark - | |
#pragma mark Singelton Pattern | |
static ACSingleton.h* _sharedInstance; | |
// Method to get the shared instance | |
+ (id)sharedInstance |
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
/build/ | |
xcuserdata | |
*.xcworkspace | |
.DS_Store |
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
#pragma mark - | |
#pragma mark Controller Lifecycle | |
// Called once the view controller is initialized in your code | |
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil | |
{ | |
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; | |
if (self) { | |
// Initialize iVars that live and die with your controller | |
_myList = [[NSMutableArray alloc] initWithCapacity:5]; |
NewerOlder