summaryrefslogtreecommitdiffstats
path: root/carbon/tkMacOSXMenubutton.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-07-31 14:39:04 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-07-31 14:39:04 (GMT)
commit57697b5b22a5851bca41ba3ec058f1de355ba5dc (patch)
tree6faf126294b1235b3307dcc394cab895489ceef6 /carbon/tkMacOSXMenubutton.c
parentd4a4017589dd52fa8e9667df9d754fd62abd6bed (diff)
downloadtk-57697b5b22a5851bca41ba3ec058f1de355ba5dc.zip
tk-57697b5b22a5851bca41ba3ec058f1de355ba5dc.tar.gz
tk-57697b5b22a5851bca41ba3ec058f1de355ba5dc.tar.bz2
minor improvements to flag handling
Diffstat (limited to 'carbon/tkMacOSXMenubutton.c')
-rw-r--r--carbon/tkMacOSXMenubutton.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/carbon/tkMacOSXMenubutton.c b/carbon/tkMacOSXMenubutton.c
index 9846d13..58fc787 100644
--- a/carbon/tkMacOSXMenubutton.c
+++ b/carbon/tkMacOSXMenubutton.c
@@ -934,7 +934,7 @@ MenuButtonEventProc(
if (eventPtr->type == ActivateNotify
|| eventPtr->type == DeactivateNotify) {
- if ((buttonPtr->tkwin == NULL) || (!Tk_IsMapped(buttonPtr->tkwin))) {
+ if ((buttonPtr->tkwin == NULL) || !Tk_IsMapped(buttonPtr->tkwin)) {
return;
}
if (eventPtr->type == ActivateNotify) {
@@ -942,8 +942,8 @@ MenuButtonEventProc(
} else {
mbPtr->flags &= ~ACTIVE;
}
- if ((buttonPtr->flags & REDRAW_PENDING) == 0) {
- Tcl_DoWhenIdle(TkpDisplayMenuButton, (ClientData) buttonPtr);
+ if (!(buttonPtr->flags & REDRAW_PENDING)) {
+ Tcl_DoWhenIdle(TkpDisplayMenuButton, buttonPtr);
buttonPtr->flags |= REDRAW_PENDING;
}
}