uinavigationcontroller

iOS: Setting text in nib subview from view in UITabBar/UINavigationController application

纵然是瞬间 提交于 2020-01-06 04:52:27
问题 I'm having a problem getting a UISearchDisplay's text value to be set programatically on load of the view by another view and my question is have I overcomplicated my problem and missed something or am I on the right track of thinking. Here's the situation: I have a UITabBarController as my root view, there are 2 tabs, both have a UINavigationController setup so I can push views as needed. Tab 1 has a UITableViewController which is populated with a list of categories. Tab 2 has a MapView in

iOS - NavController & Custom Views

霸气de小男生 提交于 2020-01-06 04:46:28
问题 The Crash: -[UIImageView setParentViewController:]: unrecognized selector sent to instance 0x58701e * Termintating app due to uncaught execption 'NSInvalidArgumentExecption', reason: '-[UIImageView setParentViewController:]: unrecognised selector sent to instance 0x58701e0' This occurs when I'm trying to push a custom UIViewController that is made without IB. When I do this with IB it works but it's not exactly what I need. What is being called for my delegate -(void)switchToTrailerOne {

UINavigationController + shouldAutoRotate + no subclassing

吃可爱长大的小学妹 提交于 2020-01-05 21:04:50
问题 I have a navigation driven app. I need that app to rotate. The UINavigationController is the root controller/view in the window. I know (and have experienced why) it is a no-no to subclass UINavigationController. I know all i have to do is insert: - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return YES; } into the UINavigationController and it will rotate fine. So my question is: how do I enable rotation on the root view controller

Proper way to handle data persistence/flow with navigation controllers?

自古美人都是妖i 提交于 2020-01-05 15:08:54
问题 Normally if I want to send information to a view controller I'm navigating to, I'll just specify it in the prepareForSegue function like so: override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject!) { let vc = segue.destinationViewController as! SomeViewController vc.info = self.info } but as far as I understand it, this only works when I am creating a new instance of the view controller that is being navigated to. Say I have a button in a navigation bar that has a (show)

Proper way to handle data persistence/flow with navigation controllers?

让人想犯罪 __ 提交于 2020-01-05 15:05:42
问题 Normally if I want to send information to a view controller I'm navigating to, I'll just specify it in the prepareForSegue function like so: override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject!) { let vc = segue.destinationViewController as! SomeViewController vc.info = self.info } but as far as I understand it, this only works when I am creating a new instance of the view controller that is being navigated to. Say I have a button in a navigation bar that has a (show)

Custom back button for NavigationController for every screen

痞子三分冷 提交于 2020-01-05 09:08:53
问题 I have been trying to subclass the UINavigationController class for modifying things like background image, navigation bar size, back button, tittle font and so on. After a couple of hours and a lot of reading I have understand that I should not subclass the UINavigationController class... I would like to have specific design and transfer that design to all screens that use my custom NavigationController... SO far I haven't fount any elegant solution for this, most of the solutions are based

Passing some data back to RootViewController iOS 7

≡放荡痞女 提交于 2020-01-05 09:00:15
问题 Suppose , We have 3 ViewControllers called ViewControllerA , ViewControllerB , ViewControllerC in our UINavigationController . To be specific , ViewControllerA is the RootViewController and ViewControllerB and ViewControllerC are pushed on it. So, Currently ViewControllerC is on the Top and visible to user. I want to return to ViewControllerA by calling [self.navigationController popToRootViewControllerAnimated:YES]; method and pass some data to ViewControllerA from here. I have to update

How to push multiple view controllers onto navigation controller

不羁的心 提交于 2020-01-05 08:48:11
问题 Newbie here programming my first app (having made several tutorial apps). I am using a view controller called 'RootViewController' as a navigation controller. I have successfully pushed another view controller on top of this called 'ClientListViewController' using the command: [self.navigationController pushViewController:clientListViewController animated:YES]; I am now in the ClientListViewController and trying to push another view controller onto the stack called 'AddClientViewController'.

How to push multiple view controllers onto navigation controller

微笑、不失礼 提交于 2020-01-05 08:47:44
问题 Newbie here programming my first app (having made several tutorial apps). I am using a view controller called 'RootViewController' as a navigation controller. I have successfully pushed another view controller on top of this called 'ClientListViewController' using the command: [self.navigationController pushViewController:clientListViewController animated:YES]; I am now in the ClientListViewController and trying to push another view controller onto the stack called 'AddClientViewController'.

Navigation bar button not showing

筅森魡賤 提交于 2020-01-05 08:43:43
问题 When try to add a navigation button on left and right side , its not showing?is this is the code i used for, Whats wrong with this? this is how i added the navigation bar in in appdelegate, UIViewController *viewController1 = [[logyFirstViewController alloc] initWithNibName:@"logyFirstViewController" bundle:nil]; UIViewController *viewController2 = [[logySecondViewController alloc] initWithNibName:@"logySecondViewController" bundle:nil]; UIViewController *viewController3 = [[record alloc]