-3

I know it's very vague and is asking a lot but does anyone know how to convert the standard iOS starter project from iPhone to iPad (both is best)? Or does anyone know where I can download one. I am a new iOS developer and am trying to start learning with Parse.

I am referring to this project https://www.parse.com/downloads/ios/parse-starter-project/latest

P.S. Just because this question isn't perfect doesn't mean you have to go and down vote and flag it for removal I don't have a lot of points already no need to lose even more :)

Isaiah Turner
  • 2,574
  • 1
  • 22
  • 35

2 Answers2

2

Not being able to see this sample project, it's hard to say for certain what it will take.

At bare minimum go into your project summary, and select "Universal" for the device support.

Above and beyond that, it just depends on what the app is and how it's structured. For NIBs, you will want a NIB for iPhone and one for iPad. I find it easy to abstract this away so that I can simplify my view loading:

MyController *myController = [[MyController alloc] initWithView:@"MyControllerView" bundle:nil];

Then in a category, I'd define initWithView similar to:

@implementation UIViewController (Universal)

-(id) initWithView:(NSString *)view bundle:(NSBundle *)nibBundle{
    bool isIpad = UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad;
    NSString *nibName = [NSString stringWithFormat:@"%@_%@", view, (isIpad ? @"iPad" : @"iPhone")];

    return [self initWithNibName:nibName bundle:nibBundle];
}

@end

But, that's just one aspect of supporting both devices. In reality the subject is rather specific to the app you're working on. Things like OS support (e.g., am I only targeting iOS 6 or higher) play a factor in things.

Jason Whitehorn
  • 13,585
  • 9
  • 54
  • 68
0

I have solved it now, if anyone needs the files email me turboecreations@iCloud.com I would upload them but I dont want my MediaFire and other accounts to be removed if I run into copyright issues.

Isaiah Turner
  • 2,574
  • 1
  • 22
  • 35