Re: NSButton alternate image problem - not redrawing
Re: NSButton alternate image problem - not redrawing
- Subject: Re: NSButton alternate image problem - not redrawing
- From: P Teeson <email@hidden>
- Date: Thu, 17 Jul 2008 13:19:42 -0400
I posted about this issue but so far only one response.
For the full details please see earlier in this thread.
This is a summary:
Initially the button has blank icons for both image and alternate image.
User clicks on button, action method is called, in that method a
different alternate image is set by,
[sender setAlternateImage:theXiconImage];
then the button is disabled by,
[sender setEnabled:NO];
the action method is exited, and button is redrawn showing the new
image.
However after doing this when the game is over:
[cell0 setAlternateImage:theBlankImage]; // send messages via IBOutlet
[cell0 setEnabled:YES];
to restore the button to it's original state, clicking on the button is
not guaranteed to result in drawing the alternate image as before
even though
going through same action method.
Sometimes it does; sometimes it doesn't -just draws blank image.
Why this unexpected behavour? Does this imply no dynamic setting of
alternate image?
But it works when first loaded from nib. Why not when button state is
reset programmatically?
I'd appreciate some help on debugging this.
Thanks...
Peter
_______________________________________________
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