uinavigationcontroller

Receive error when trying to post on Twitter using ShareKit

本小妞迷上赌 提交于 2019-12-23 10:12:27
问题 I'm trying to use sharekit to post on Twitter and Facebook. I have two buttons which call the following two methods: - (IBAction) shareOnFacebook:(id)sender { // Create the item to share NSString *someText = @"Share on Facebook."; SHKItem *item = [SHKItem text:someText]; // Share the item [[SHK currentHelper] setRootViewController:self.navigationController]; [SHKFacebook shareItem:item]; } - (IBAction) shareOnTwitter:(id)sender { // Create the item to share NSString *someText = @"Share on

How to hide Navigation Controller in Root View?

感情迁移 提交于 2019-12-23 09:05:20
问题 Please, help me to hide navigation controller in root view. I've found the solution to write [navigationController setNavigationBarHidden:YES] in every view controller which I need. Well, it works but only for the first time: I run application, in root view I don't have navigation, then I go to the second view – the navigation appears, OK. But then I press "Back" in navigation controller, and navigation from root view hasn't disappear. I work with xib. 回答1: In rootViewController -(void

Invisible back button when view controller pushed onto navigation controller

半腔热情 提交于 2019-12-23 08:56:10
问题 I'm using a navigation controller to drill into a detail view when a cell is tapped. When I push my view controller onto the navigation controllers stack, I expect to see a back button that I can tap to pop the previous view off the stack. The issue is that the back button isn't visible, but when tapping where it should be returns me to the previous view. What's the problem? 回答1: Ensure you have set a title for the master view - for example in viewDidLoad add this - self.title = @"The Title";

How can I make UIPopoverPresentationController resize on navigation pop?

爷,独闯天下 提交于 2019-12-23 07:38:10
问题 I'm using UIPopoverPresentationController for popovers in an iOS app. When a navigation controller in a popover pushes a new view controller, the popover resizes to that view controller's preferredContentSize . But when the navigation controller pops a view controller off the stack, the popover does not resize to the previous size. How can I make it do that? Possible duplicate of this question, but for the modern UIPopoverPresentationController . Update: See here for example code illustrating

iOS - [UIColor clearColor] and UIToolbars

帅比萌擦擦* 提交于 2019-12-23 05:27:09
问题 I've been attempting to use [UIColor clearColor] with UIToolbar in an attempt to make a custom control interface more fitting of a "Mechanical" application (Think buttons you would see in a Movie from the 70s). What is happening is that when I set the toolbar to clearColor it is turning it matte black. The image behind it is red, tan and black so I'm sure it's not working as intended. One difference I see is that I'm using the toolbar on a nav controller and not a stand alone UIToolbar . The

Real time blur effect for Navigation Bar - Status bar not getting in

蹲街弑〆低调 提交于 2019-12-23 05:22:35
问题 Followed this question to get real time blur effect in Navigation Bar: func addBlurEffect() { var bounds = self.navigationController?.navigationBar.bounds as CGRect! var visualEffectView = UIVisualEffectView(effect: UIBlurEffect(style: .Light)) as UIVisualEffectView visualEffectView.frame = bounds visualEffectView.autoresizingMask = .FlexibleHeight | .FlexibleWidth self.navigationController?.navigationBar.addSubview(visualEffectView) } But the status bar remains translucent: How to fix it?

iPhone UINavigationController Back Button Missing

半腔热情 提交于 2019-12-23 05:15:00
问题 In am currently creating a Navigation-based application for the iPhone, where the root view of the NavigationController is the main menu (home). There are 3 other views (named View1, View2 and View3), which can be accessed in this manner; main menu -> View1 -> View2 -> View3. Each of the Views has a 'Home button' that will call 'popToRootViewControllerAnimated' and return to the main menu. When this button is pressed in View2, it returns to the main menu. However, when you go from the main

Switch between different Views in SWIFT

丶灬走出姿态 提交于 2019-12-23 04:50:26
问题 I read a lot of questions / answers in the stack overflow community about switching between different ViewControllers but I couldn't find the correct answer for my specific problem. I'm using a NavigationViewController to "connect" all my different viewControllers (ViewController / TableViewController / CollectionViewController) I have got some classes which aren't depending on a ViewController class. For example to to calculate anything in my "calculate" class. I'm searching for an easy

Navigation Bar customization in ios4 doesnt work in ios5

杀马特。学长 韩版系。学妹 提交于 2019-12-23 04:45:06
问题 i know that this question looks the same as other around here, but none of them say anything about incompatibility between ios4 and ios5. In my app i want to customize the pattern of the navigation Bar, but my deployment target is ios4, so i am using the code bellow above the implementation of the appDelegate.m to do this: @implementation UINavigationBar (CustomImage) - (void)drawRect:(CGRect)rect { UIColor *color = [UIColor blackColor]; UIImage *image = [UIImage imageNamed: @"nav_bar.png"];

Swift - TabBarController -> ViewController -> NavigationController

喜欢而已 提交于 2019-12-23 04:37:28
问题 i have the following situation: I got a TabBarController with some tabs(ViewControllers). When i am in one of these ViewControllers, i tap a button and i want to segue to a NavigationController AND still see the tabbar... Here is what i did: I created a new ViewController(DetailViewController) I embedded this new ViewController(DetailViewController) in a NavigationController I created a segue(Show) from the "viewcontroller which is embedded in the tabbarcontroller" to the "new