Re: NSPopUpButton Notifications
Re: NSPopUpButton Notifications
- Subject: Re: NSPopUpButton Notifications
- From: "I. Savant" <email@hidden>
- Date: Tue, 22 May 2007 11:48:36 -0400
On 5/22/07, MH <email@hidden> wrote:
Correct! mouseUp was not being called.
Then a search for something simple like "mouseUp: not called" on
this list produces this:
http://www.cocoabuilder.com/archive/message/cocoa/2007/4/3/181328
... a good explanation as to why that might not work.
I realised that my problem was a non-problem and that I was trying to
subclass NSPopUpButton to obtain a mouseUp notification when the
setAction method of NSControl from which it inherits provides the
desired results, i.e. the opportunity to query the PopUp for the index
of the selected item once the user has finished selecting.
An excellent reason to follow:
http://www.catb.org/~esr/faqs/smart-questions.html
... had you explained what you're trying to do in general terms,
then posted what you tried (you did that), then posted what you were
expecting to happen versus what actually happened, we could've saved
many back-and-forths and you could've gotten a quick answer (that is,
"use the target/action mechanism, silly!") as well as learn something
new (that generally most controls handle everything in a -mouseDown:
loop and -mouseUp: doesn't normally get called).
--
I.S.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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