• 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
NSButton event waits until setEnabled is executed?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSButton event waits until setEnabled is executed?


  • Subject: NSButton event waits until setEnabled is executed?
  • From: "Dae Suk Chai" <email@hidden>
  • Date: Mon, 28 Jul 2008 15:54:31 -0700

Hey all,  I have a small cocoa app, which basically behaves like an regular
installation program.

The problem I am facing is the following :

1) User clicks so called "Next" button,  I would hide that button and
disable it using the following function (fHide = YES)

-(void) hideButton:(NSButton*) pButton Hide:(BOOL) fHide
{
    if(fHide)
        NSLog(@"@@@@@@@@@ Button Hidden @@@@@@@@@@");
    else
        NSLog(@"@@@@@@@@@ Button displayed @@@@@@@@@@");

    [pButton setHidden:fHide];
    [pButton setEnabled:!fHide];
}



2) But whenever user makes multiple clicks on the empty space (where the
button was previously located),  then I call this function again with (fHide
= NO), the button gets pressed automatically even though I am not even
pressing anything.   And "YES" I made sure that the user didn't accidentally
click the button after the button is displayed.

Thank you in advance

Max
_______________________________________________

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: Transparent colors
  • Next by Date: Pre-requisites for automatic image highlighting in NSButton?
  • Previous by thread: Re: Transparent colors
  • Next by thread: Pre-requisites for automatic image highlighting in NSButton?
  • Index(es):
    • Date
    • Thread