uiviewcontroller

preferredStatusBarUpdateAnimation being ignored

不想你离开。 提交于 2020-01-03 09:39:41
问题 I have AuthViewController that is presenting MainViewController like so: let mainVC = MainViewContoller() mainVC.modalTransitionStyle = .CrossDissolve authVC.presentViewController(mainVC, animated: true, completion: nil) I want the AuthViewController to hide the status bar, but the MainViewController to show, like so: AuthViewController { override func preferredStatusBarStyle() -> UIStatusBarStyle { return .LightContent } override func preferredStatusBarUpdateAnimation() ->

preferredStatusBarUpdateAnimation being ignored

岁酱吖の 提交于 2020-01-03 09:39:11
问题 I have AuthViewController that is presenting MainViewController like so: let mainVC = MainViewContoller() mainVC.modalTransitionStyle = .CrossDissolve authVC.presentViewController(mainVC, animated: true, completion: nil) I want the AuthViewController to hide the status bar, but the MainViewController to show, like so: AuthViewController { override func preferredStatusBarStyle() -> UIStatusBarStyle { return .LightContent } override func preferredStatusBarUpdateAnimation() ->

Managing View Controllers in iPad port

假装没事ソ 提交于 2020-01-03 03:46:05
问题 I've got an app that I've developed for the iPhone, but now want to port to the iPad. The iPhone app is navigation style and based on discrete table view controllers managed by a nav controller. The larger screen real estate of the iPad means that I can comfortably fit a couple of these table view controllers on to the screen at the same time. The question is how? Should I a) have the main view load two table view controllers from separate NIBs and then position them on screen (I'm not sure

willAnimateRotationToInterfaceOrientation not called on ios6/7

半腔热情 提交于 2020-01-03 03:34:21
问题 I have an old app, that still lives on iTunes, written in iOS 5. I would like to update it to run on ios 6 and 7. Everything has been fine so far, and I have updated my code to use ARC. However when trying to maintain the same autorotation philosophy I keep hitting a brick wall. I have already checked relative topics within SO like: Forcing landscape and autorotate in iOS 7, Autorotate in iOS 6 has strange behaviour and following a similar topic I have found this: iOS 6 Autorotation Problems

iOS - load and switch between pages using UIPageContol

一世执手 提交于 2020-01-03 03:26:22
问题 I would like to use UIPageControl to navigate between different view controllers. I have 2 view controllers and another main view controller contains the UIPageControl . The 2 view controllers to be navigated between have been added as children to the main view controller. When I currently start the application, I see a blank screen. I used pageControl.currentPage = 0 but I am unable to understand why I am unable to see the views. Note that I do not want to use UIScrollView in my application.

How to make viewDidLoad method of ViewController call only once?

老子叫甜甜 提交于 2020-01-03 02:55:11
问题 I created a Container View in my application. The container view loads other UIViewController when user tabs on a UITableviewCell and other UIViewController gets loaded inside the Container View. I tried testing by inserting log messages on other ViewController class and found out each time viewDidLoad and ViewDidAppear method gets called which states those class gets instantiated everytime on cell tab. But while studying about container view on the apple docs https://developer.apple.com

Is calling updateViewConstraints manually a good idea?

橙三吉。 提交于 2020-01-02 23:13:58
问题 I'm creating my constraints mainly in viewDidLoad . In updateViewConstraints I'm adding or removing some subviews and additionally adding and removing constraints. As a side note I'm using a container with child view controllers and I'm reusing the same view for different orientations (full in landscape, in a popover in portrait). Because I have my complete setup in updateViewConstraints I have to call it in some situations manually to adapt the visual changes and not to brake the constraints

Remove view controller from another view controller

◇◆丶佛笑我妖孽 提交于 2020-01-02 20:44:35
问题 I am very new to iPhone app development. I am developing one example application for iPhone emulator using Objective-C++ and std CPP. I have two views in my application, on some events from CPP code i am displaying second view using following code from the first view controller. // Defined in .h file secondViewScreenController *mSecondViewScreen; // .mm file Code gets called based on event from CPP (common interface function between Objective-C++ and CPP code) mSecondViewScreen = [

Remove view controller from another view controller

余生长醉 提交于 2020-01-02 20:43:40
问题 I am very new to iPhone app development. I am developing one example application for iPhone emulator using Objective-C++ and std CPP. I have two views in my application, on some events from CPP code i am displaying second view using following code from the first view controller. // Defined in .h file secondViewScreenController *mSecondViewScreen; // .mm file Code gets called based on event from CPP (common interface function between Objective-C++ and CPP code) mSecondViewScreen = [

Is it possible to use iOS 7 UIViewController transitions (interactive specifically) with child view controllers?

▼魔方 西西 提交于 2020-01-02 15:25:26
问题 There's many tutorials floating around about using the new iOS 7 UIViewController transitions API and the great new interactive transition API. However, none of these seem to reference adding and removing child view controllers interactively, despite in the WWDC 2013 video on Custom UIViewController Transitions the Apple employee shows what I would imagine to be a child view controller presented with a custom transition: (I'm assuming this as a view controller is shown on top of another one