Discussion Forums  >  Uncategorized

Replies: 9    Views: 559

paulwyre
Apple Fan
Profile
Posts: 139
Reg: Dec 21, 2010
USA
1,390
02/03/11 02:33 PM (15 years ago)

no .xib files

Anyone know how I can add a photo picker to the applications. I noticed theres no .xib files for interface builder and I was going to add some custom features to the application.
 
aussiedra
Code is Art
Profile
Posts: 431
Reg: Dec 25, 2010
Brisbane, Austr...
8,260
like
02/03/11 05:53 PM (15 years ago)
xib file would have been nice but they are removed from the source.
 
paulwyre
Apple Fan
Profile
Posts: 139
Reg: Dec 21, 2010
USA
1,390
like
02/03/11 06:15 PM (15 years ago)
this also complicates the adding of iad's :-/
 
aussiedra
Code is Art
Profile
Posts: 431
Reg: Dec 25, 2010
Brisbane, Austr...
8,260
like
02/03/11 07:40 PM (15 years ago)
i had to edit alot of the code image sizes to add a iad example AppDetailsViewController.m //webView for details. detailsWebView = [[UIWebView alloc] initWithFrame:CGRectMake(12, 115, 299, 292)]; detailsWebView.delegate = self; detailsWebView.scalesPageToFit = YES; detailsWebView.dataDetectorTypes = UIDataDetectorTypeAll; detailsWebView.backgroundColor = [UIColor clearColor]; detailsWebView.opaque = NO; [self.view addSubview:detailsWebView]; after 3 hours i did it i will see how 1.5 code look and write up a doco how to do it
 
paulwyre
Apple Fan
Profile
Posts: 139
Reg: Dec 21, 2010
USA
1,390
like
02/03/11 07:49 PM (15 years ago)
ouch...With .xib just import the iad framework then drag the iad banner into the app :-/ Thanks i'll give this a shot :-)
 
paulwyre
Apple Fan
Profile
Posts: 139
Reg: Dec 21, 2010
USA
1,390
like
02/03/11 07:59 PM (15 years ago)
hmm that code is the exact code I already have.
 
aussiedra
Code is Art
Profile
Posts: 431
Reg: Dec 25, 2010
Brisbane, Austr...
8,260
like
02/03/11 08:41 PM (15 years ago)
Paste after the : //did rotate
 
aussiedra
Code is Art
Profile
Posts: 431
Reg: Dec 25, 2010
Brisbane, Austr...
8,260
like
02/03/11 08:42 PM (15 years ago)
//iAD Codes - (void)createAdBannerView { Class classAdBannerView = NSClassFromString(@ADBannerView); if (classAdBannerView != nil) { self.adBannerView = [[[classAdBannerView alloc] initWithFrame:CGRectZero] autorelease]; [_adBannerView setRequiredContentSizeIdentifiers:[NSSet setWithObjects: ADBannerContentSizeIdentifier320x50, ADBannerContentSizeIdentifier480x32, nil]]; if (UIInterfaceOrientationIsLandscape([UIDevice currentDevice].orientation)) { [_adBannerView setCurrentContentSizeIdentifier: ADBannerContentSizeIdentifier480x32]; } else { [_adBannerView setCurrentContentSizeIdentifier: ADBannerContentSizeIdentifier320x50]; } [_adBannerView setFrame:CGRectOffset([_adBannerView frame], 0, -[self getBannerHeight])]; [_adBannerView setDelegate:self]; [self.view addSubview:_adBannerView]; } }
 
aussiedra
Code is Art
Profile
Posts: 431
Reg: Dec 25, 2010
Brisbane, Austr...
8,260
like
02/03/11 08:42 PM (15 years ago)
- (void)fixupAdView:(UIInterfaceOrientation)toInterfaceOrientation { if (_adBannerView != nil) { if (UIInterfaceOrientationIsLandscape(toInterfaceOrientation)) { [_adBannerView setCurrentContentSizeIdentifier: ADBannerContentSizeIdentifier480x32]; } else { [_adBannerView setCurrentContentSizeIdentifier: ADBannerContentSizeIdentifier320x50]; } [UIView beginAnimations:@fixupViews context:nil]; if (_adBannerViewIsVisible) { CGRect adBannerViewFrame = [_adBannerView frame]; adBannerViewFrame.origin.x = 0; adBannerViewFrame.origin.y = 360; [_adBannerView setFrame:adBannerViewFrame]; CGRect contentViewFrame = progressView.frame; contentViewFrame.origin.y = [self getBannerHeight:toInterfaceOrientation]; contentViewFrame.size.height = self.view.frame.size.height - [self getBannerHeight:toInterfaceOrientation]; progressView.frame = contentViewFrame; } else { CGRect adBannerViewFrame = [_adBannerView frame]; adBannerViewFrame.origin.x = 0; adBannerViewFrame.origin.y = -[self getBannerHeight:toInterfaceOrientation]; [_adBannerView setFrame:adBannerViewFrame]; CGRect contentViewFrame = progressView.frame; contentViewFrame.origin.y = 0; contentViewFrame.size.height = self.view.frame.size.height; progressView.frame = contentViewFrame; } [UIView commitAnimations]; } } - (void)viewDidLoad { [self createAdBannerView]; }
 
paulwyre
Apple Fan
Profile
Posts: 139
Reg: Dec 21, 2010
USA
1,390
like
02/03/11 09:06 PM (15 years ago)
I have//did rotate in 16 files and posted this in them and got over 100 errors :-/
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.