uistoryboard

Best way to use multiple storyboards in app

大憨熊 提交于 2019-12-10 11:18:16
问题 I'm currently working on an app that will be using multiple story boards as follows: 1) login.storyboard (handles registration and login) 2) main.storyboard (handles game options and selection) 3) settings.storyboard (handles settings for game(s)) 4) game.storyboard (actualy game play) I currently test for a session token in NSUserDefaults and if it exists, load the main.storyboard otherwise auth.storyboard using: NSUserDefaults *tagDefaults = [NSUserDefaults standardUserDefaults]; if (!

Error compiling storyboard files using Xcode 6 beta 5

て烟熏妆下的殇ゞ 提交于 2019-12-10 03:32:04
问题 My app was building fine in Xcode 6 Beta 4. I updated to Beta 5 today and ran into 2 errors: The file “Storyboard_iPad-SBPartialInfo.plist” couldn’t be opened because there is no such file. Command /Applications/Xcode6-Beta5.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ibtool failed with exit code 255 What is that SBPartialInfo.plist? I could not search for it via spotlight. My Storyboard files are storyboard_iphone and storyboard_ipad 回答1: I was also

Pass data back with dismissViewControllerAnimated

邮差的信 提交于 2019-12-09 18:05:34
问题 I have a FirstViewController and a SecondViewController . I created a button in FirstViewController in order to perform a segue modally to SecondViewController . In SecondViewController I have a tableView showing a list of 8 items, as I select an item from that list, I dismissViewControllerAnimated: , going back to FirstViewController . What I would like to do is pass a string back to the FirstViewController . I used this post as a reference for my code: dismissModalViewController AND pass

How do I reset specific size class data on a storyboard in Xcode6?

落花浮王杯 提交于 2019-12-09 16:01:29
问题 I am using size classes to create a storyboard that can target all the various screen sizes and orientations. I have been working in the Any Width-Any Height size class. I ran into a display issue and decided to make those changes in the Compact Width - Regular Height size class. At a Later time, I was able to resolve my layout issue by making constraint changes to the Any Width-Any Height size class. How can I revert the changes made to the Compact Width - Regular Height size class so that

Create a standalone view in storyboard to use programmatically

假如想象 提交于 2019-12-09 05:16:42
问题 I'm trying to create and design a UIView using a storyboard but include it in a UIActionSheet programmatically. This is basically to avoid using CoreGraphics positioning functions with pixels In old xcode I remember that it was possible to drag a UIView onto the nib without any controllers. The view obviously has to be connected to the class, so it would have an IBOutlet, but not being added to the self.view One thing that makes me feel like this should be possible is that if you drag a

Using UITabBarController with UINavigationController - Swift 3

不羁的心 提交于 2019-12-09 03:59:52
问题 I am making an app which requires a use of a UITabBarController along with UINavigationController . I have made the following flow in storyboard. See image Now the first question is that is this accepted by Apple, as there are too many discussions for the same. The other matter of concern is that is it possible to eliminate any UINavigationController and still get the same flow of the app? The main thing required is to have the SAME tab bar and navigation bar on all sub tabs of the tabs. One

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

prepareForSegue equivalent in WatchKit

耗尽温柔 提交于 2019-12-09 02:39:53
问题 I have an interface with 2 buttons, both of them call the same interface but with different information. On the traditional interface I use prepareForSegue, but I don't know what's the equivalent one on the WatchKit. 回答1: You can do this in two ways: In your storyboard you set an identifier in your segue: and then you can use contextForSegueWithIdentifier : - (id)contextForSegueWithIdentifier:(NSString *)segueIdentifier { if ([segueIdentifier isEqualToString:@"yourIdentifier"]) { return

How To Convert A View Controller Animation Transition To A Segue Animation Transition

丶灬走出姿态 提交于 2019-12-09 01:21:22
问题 From what I can gather it is not possible to use a View Controller animation as a Segue transition. Currently I have a set of View Controller animations in an existing project that create animated transitions between View Controllers. For example: Modal Animation .h File: // // MVModalDismissAnimation.h // #import "MVBaseAnimation.h" @interface MVModalAnimation : MVBaseAnimation @end Modal Animation .m File: // // MVModalDismissAnimation.m // #import "MVModalAnimation.h" @implementation

Why do my prototype cells show up blank?

≯℡__Kan透↙ 提交于 2019-12-08 19:57:26
In a uitableview in my storyboard, I have defined a prototype cell. In that cell (a custom class kzTexturedCellv2) I have a text view and an image view. I have also given the cell an identifier ("kzTexturedCellv2") and used - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { kzTexturedCellv2 *cell = [[kzTexturedCellv2 alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"kzTexturedCellv2"]; ... to create the cells. The problem is that the cells show up blank (without any of the subviews that I added in storyboad.) When I try to