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
| Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. | |
| /Users/egray/.rvm/rubies/ruby-1.8.7-head/bin/ruby extconf.rb | |
| checking for main() in -lc... yes | |
| creating Makefile | |
| make | |
| /usr/local/opt/apple-gcc42/bin/gcc-4.2 -I. -I. -I/Users/egray/.rvm/rubies/ruby-1.8.7-head/lib/ruby/1.8/i686-darwin14.0.0 -I. -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -fno-common -O3 -I/usr/local/opt/libyaml/include -I/usr/local/opt/readline/include -I/usr/local/opt/libksba/include -I/usr/local/opt/openssl098/include -fno-common -pipe -fno-common -O0 -Wall -Werror -c gherkin_lexer_ar.c | |
| couldn't understand kern.osversion `14.0.0' | |
| cc1: warnings being treated as errors |
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
| typedef NS_ENUM(NSInteger, MySwitchType) { | |
| MyUserDefaultPreference1, | |
| MyUserDefaultPreverence2 | |
| } | |
| - (void)someSwitchSetup { | |
| UISwitch *aSwitch = [UISwitch new]; | |
| aSwitch.tag = MyUserDefaultPreference1; // Could be MyUserDefaultBackgroundOn // BackgroundOff etc | |
| [aSwitch addTarget:self selector:@selector(tapForUserDefaultChange:) forState:UIStateEventChanged]; // I cant remember the state change off the top of my head |
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
| *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UIViewController _loadViewFromNibNamed:bundle:] loaded the "CPClientForm" nib but the view outlet was not set.' | |
| *** First throw call stack: | |
| ( | |
| 0 CoreFoundation 0x0194c946 __exceptionPreprocess + 182 | |
| 1 libobjc.A.dylib 0x015d5a97 objc_exception_throw + 44 | |
| 2 CoreFoundation 0x0194c86d +[NSException raise:format:] + 141 | |
| 3 UIKit 0x01e56708 -[UIViewController _loadViewFromNibNamed:bundle:] + 498 | |
| 4 UIKit 0x01e56dbb -[UIViewController loadView] + 295 | |
| 5 UIKit 0x01e56fef -[UIViewController loadViewIfRequired] + 78 | |
| 6 UIKit 0x01e57595 -[UIViewController view] + 35 |
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
| // Child 1 | |
| @interface LineOneView : SuperView | |
| @property (nonatomic) UISwitch *foo, bar; | |
| @end | |
| @implementation LineOneView | |
| @end | |
| // Child 2 | |
| @interface LineTwoView : SuperView |
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 <UIKit/UIKit.h> | |
| @interface CPControlSwitch : UISwitch { | |
| BOOL _switchState; | |
| } | |
| - (void)setSwitchState:(BOOL)switchState; | |
| - (BOOL)isSwitchState; | |
| @end | |
| @implementation MySwitch |
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
| - (void)awakeFromNib { | |
| [super awakeFromNib]; | |
| // tap and call boxTapped | |
| UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(boxTapped:)]; | |
| tap.numberOfTapsRequired = 1; | |
| tap.cancelsTouchesInView = NO; | |
| // Some outlet views i wanna tap on | |
| NSArray *controls = @[self.brandNewBox, self.reprintBox, self.alterExistingBox, self.suppliedBox, self.alterSuppliedBox]; | |
| // Assign tap gesture to all those views | |
| for (UIView *controlView in controls) { |
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 <UIKit/UIkit.h> | |
| @interface TableViewController : UIViewController | |
| @property (nonatomic) UITableView *tableView; | |
| @end | |
| @implementation TableViewController <UITableViewDelegate, UITableViewDataSource, MyCellControlProtocol> |
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
| // | |
| // ViewController.m | |
| // comprintapp | |
| // | |
| // Created by Ellis Gray on 8/01/2015. | |
| // Copyright (c) 2015 Ellis Gray. All rights reserved. | |
| // | |
| #import "ViewController.h" | |
| #import "NavController.h" |
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
| - (void) someSetupMethod { | |
| UIView *view = [UIView new]; | |
| view.userInteractionEnabled = YES; | |
| // Target is self, self is the controller that you're in right now and will call the method iGotTapped: on itself. | |
| UIGestureRecognizer *tap = [[UIGestureRecognizer alloc] initWithTarget:self action:@selector(iGotTapped:)]; | |
| // addGesture to view | |
| [view addGestureRecognizer:tap]; | |
| } |