• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Overriding target and action of backBarButtonItem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Overriding target and action of backBarButtonItem


  • Subject: Overriding target and action of backBarButtonItem
  • From: charisse napeÿfffff1as <email@hidden>
  • Date: Fri, 14 Jan 2011 01:17:58 -0800 (PST)

Hello Guys,

I have trouble setting the action for my backbarbutton item. No matter how I set
it, my selector does not get called.
Here is my code below:


        UIBarButtonItem *backB = [[UIBarButtonItem alloc] init];
backB.title = @"Back";
backB.action = @selector(disconnect:);
	self.navigationItem.backBarButtonItem = backB;
	[backB release];

Assume I created a disconnect() function already.

But if I use leftBarButtonItem my function gets called. Is this because the
backBarButton item already has its function to dismiss the view? Can't I
override it somehow?


Thanks,
Charisse



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: Maintaining NSCursor outside of app window
  • Next by Date: Re: sending a message from an initializer method
  • Previous by thread: Re: Maintaining NSCursor outside of app window
  • Next by thread: Re: Overriding target and action of backBarButtonItem
  • Index(es):
    • Date
    • Thread