Last active
February 9, 2016 04:29
-
-
Save RyanFriedman/8fe26e6d768301d1a57f to your computer and use it in GitHub Desktop.
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
// | |
// HMNewTermsViewController.h | |
// Hypemarket | |
// | |
// Created by Ryan Friedman on 2/8/16. | |
// Copyright © 2016 vibrantlight. All rights reserved. | |
// | |
#import <UIKit/UIKit.h> | |
#import "HMViewController.h" | |
@interface HMNewTermsViewController : HMViewController | |
@end |
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
// | |
// HMNewTermsViewController.m | |
// Hypemarket | |
// | |
// Created by Ryan Friedman on 2/8/16. | |
// Copyright © 2016 vibrantlight. All rights reserved. | |
// | |
#import "HMNewTermsViewController.h" | |
@interface HMNewTermsViewController () | |
@end | |
@implementation HMNewTermsViewController | |
- (void)viewDidLoad { | |
[super viewDidLoad]; | |
// Do any additional setup after loading the view. | |
[self.titleLabel setText:@"CONFIRM TERMS"]; | |
[self.titleLabel sizeToFit]; | |
} | |
- (void)didReceiveMemoryWarning { | |
[super didReceiveMemoryWarning]; | |
// Dispose of any resources that can be recreated. | |
} | |
/* | |
#pragma mark - Navigation | |
// In a storyboard-based application, you will often want to do a little preparation before navigation | |
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { | |
// Get the new view controller using [segue destinationViewController]. | |
// Pass the selected object to the new view controller. | |
} | |
*/ | |
@end |
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
// | |
// HMViewController.m | |
// Hypemarket | |
// | |
// Created by Ryan Friedman on 2/8/16. | |
// Copyright © 2016 vibrantlight. All rights reserved. | |
// | |
#import "HMViewController.h" | |
@interface HMViewController () | |
@end | |
@implementation HMViewController | |
@synthesize titleLabel; | |
- (id)init | |
{ | |
NSLog(@"override the init"); | |
self = [super init]; | |
if (self) { | |
self.view.backgroundColor = [UIColor whiteColor]; | |
titleLabel = [[HMNavigationLabel alloc] initWithFrame:CGRectZero]; | |
[titleLabel setTextColor:[UIColor whiteColor]]; | |
[titleLabel setShadowColor:[UIColor colorWithWhite:0.0 alpha:0.0]]; | |
self.navigationItem.titleView = self.titleLabel; | |
UIBarButtonItem *close = [[UIBarButtonItem alloc] initWithTitle:@"Close" | |
style:UIBarButtonItemStylePlain | |
target:self | |
action:@selector(close)]; | |
[self.navigationItem setLeftBarButtonItem:close]; | |
} | |
return self; | |
} | |
- (void)close | |
{ | |
[self dismissViewControllerAnimated:YES completion:nil]; | |
} | |
/* | |
#pragma mark - Navigation | |
// In a storyboard-based application, you will often want to do a little preparation before navigation | |
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { | |
// Get the new view controller using [segue destinationViewController]. | |
// Pass the selected object to the new view controller. | |
} | |
*/ | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment