ios-universal-app

Universal Autolayout for Scrollview & UI components

情到浓时终转凉″ 提交于 2019-12-11 16:32:12
问题 I know auto layout but I am new to universal application with auto layout. I am having problem setting up Constrain to this below image. Can you tell me how do I set auto layout for Universal App? I tried with constrain to margin & pin the leading,top,trailing space to container but it does not work. 回答1: Actually, autolayout works different inside a scrollview than in other views. Inside a scroll view, the leading, trailing, top and bottom constraints form a superview to the container view

Use UITabBarViewController in portrait but UISplitViewController in landscape in a Universal app

你说的曾经没有我的故事 提交于 2019-12-09 12:56:11
问题 I want to use a UITabBarViewController when on iPhone in portrait and a UISplitViewController when on iPhone 6/6+ in landscape or iPad in either orientation. When on iPad or iPhone 6/6+ landscape, the tab bar items present themselves as UITableViewCells in the topmost view controller. I would really like for the calling object to not have to worry about device or orientation, but instead pass as input the view controllers that are in the tab bar on iPhone in portrait and in the root view

How/whether to make a universal storyboard in Xcode

血红的双手。 提交于 2019-12-09 03:11:10
问题 When creating a storyboard file in Xcode, you must select if it is for iPhone or iPad. This implies one should always put iPhone and iPad UIs into separate storyboards. Is this true? My app has multiple storyboards. While the Main.storyboard files largely differ between iPhone and iPad, other storyboards are nearly identical. The only difference might be segue being a push on iPhone vs popover on iPad, which can be handled programmatically. It seems awfully silly and redundant to make two

Using different storyboards for different screen sizes? universal xcode app

倾然丶 夕夏残阳落幕 提交于 2019-12-07 14:07:44
问题 I submitted my app for review and got the error 2.10 - iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution. We noticed that your app did not run at iPhone resolution when reviewed on iPad running iOS 9.1, which is a violation of the App Store Review Guidelines. We’ve attached screenshot(s) for your reference. Specifically, when we tap to login with Facebook on the iPad no action is produced and we are unable to get the app to advance.

Hiding UISplitViewController overlay in portrait

荒凉一梦 提交于 2019-12-07 01:26:08
问题 In adopting the new UISplitViewController I'm trying to make a change a default behaviour that occurs when using the UISplitViewControllerDisplayModeAutomatic mode. When working in portrait I want the primary overlay to hide when the user triggers a push to the detail side. By default the overlay remains onscreen until the user taps over on the detail side. I've tried using the following with the delegate: - (BOOL)splitViewController:(UISplitViewController *)splitViewController

Universal cocos2d game to support iPad3

陌路散爱 提交于 2019-12-06 06:13:46
问题 How would the image resources be named for the ipad & ipad HD versions in a universal app? When supporting normal and HD images for iphone we use imageName.png & imageName-hd.png . But if I make an universal am I right in assuming that I would have to rename the images and use imageNameiPad.png & imageNameiPad-hd.png ? Please let me know how the naming convention works. Thanks Abhinav 回答1: The correct way in cocos2d (version 2.0 or 1.1beta) is this: Normal iPhone: image.png Retina iPhone:

Hiding UISplitViewController overlay in portrait

巧了我就是萌 提交于 2019-12-05 05:13:14
In adopting the new UISplitViewController I'm trying to make a change a default behaviour that occurs when using the UISplitViewControllerDisplayModeAutomatic mode. When working in portrait I want the primary overlay to hide when the user triggers a push to the detail side. By default the overlay remains onscreen until the user taps over on the detail side. I've tried using the following with the delegate: - (BOOL)splitViewController:(UISplitViewController *)splitViewController showDetailViewController:(UIViewController *)vc sender:(id)sender { if (splitViewController.displayMode ==

Best Practice: How to handle code differences for iOS App when creating free and paid version?

落花浮王杯 提交于 2019-12-04 16:42:29
I want to release two versions, of my iOS App on the AppStore. One is paid and other is free. As of now my code is finished for the paid App. Now I want to add more code for iAd and InAppPurchase's for the free app. What is the best approach for maintaining the two versions? I was thinking about copying the Xcode Project or creating a branch in my git repo. If you branch or copy the project you're creating a maintenance nightmare for yourself down the road. Create a separate target in the same project, specific differences can be handled via #ifdef blocks in the code. Add defines to each

Universal cocos2d game to support iPad3

﹥>﹥吖頭↗ 提交于 2019-12-04 09:23:55
How would the image resources be named for the ipad & ipad HD versions in a universal app? When supporting normal and HD images for iphone we use imageName.png & imageName-hd.png . But if I make an universal am I right in assuming that I would have to rename the images and use imageNameiPad.png & imageNameiPad-hd.png ? Please let me know how the naming convention works. Thanks Abhinav The correct way in cocos2d (version 2.0 or 1.1beta) is this: Normal iPhone: image.png Retina iPhone: image-hd.png Normal iPad: image-ipad.png Retina iPad: image-ipadhd.png You must just call image.png in your

How to migrate from iPhone/iPad storyboards to universal storyboard

可紊 提交于 2019-12-04 02:48:15
I have a project created in Xcode 5. The "Deployment Info" settings says Devices: Universal but has separate iPhone and iPad settings and corresponding iPhone and iPad storyboards. Now I'm developing the same project in Xcode 6 and I want to use one universal storyboard instead of two storyboards. I have only worked on the iPhone storyboard and haven't touched the iPad one. Is it possible to ditch the iPad storyboard and convert the existing iPhone storyboard to be my main universal storyboard? DogEatDog I adapted this tutorial and a similar solution by @tharkay to create this solution below.