UINavigationBar question

Discussion in 'iOS Programming' started by brat2, Mar 30, 2009.

  1. brat2 macrumors newbie

    Feb 18, 2009
    Hi all

    I am using UINavigationBar and its showButtonsWithLeftTitle method.

    Application is working fine but I have a warrning while compiling that UINavigationBar may not respond to this method and so on...

    Actually I didn't find such method in UIKit/UINavigationBar.h

    So why is it working if there is no such method declared, or what should I import to take this warrning away ?
  2. yayaba macrumors 6502

    Apr 24, 2007
    San Francisco Bay Area
    Is that method deprecated? You might be missing a parameter or two. Double check the correct version documentation with the version you're compiling for.
  3. brat2 thread starter macrumors newbie

    Feb 18, 2009
    actually I didn't find such method in <UIKit/UINavigationBar.h> header file as I wrote

    how can this method be depricated if it works on simulator and on device ?
  4. jnic macrumors 6502a

    Oct 24, 2008
    If it's not a published API method then don't use it, it's liable to be removed in future and may result in your app being rejected from review.
  5. PhoneyDeveloper macrumors 68040


    Sep 2, 2008
    That method is a private method of UINavigationBar. If you use it then your app may not be allowed on the app store.

    What are you using it for and can you replace that functionality with public methods?

    Edit: Apparently that method was present in v1.x of UIKit but was deprecated in v2.0. You should simply be able to create your UIBarButtonItems and add them to the navbar and set the title of the view controller.

Share This Page