/* Flag which when set indicates a dialog or menu has been posted by
Xt on behalf of one of the widget sets. */
-static int popup_activated_flag;
+int popup_activated_flag;
static int next_menubar_widget_id;
return popup_activated_flag;
}
-
/* This callback is invoked when the user selects a menubar cascade
pushbutton, but before the pulldown menu is posted. */
LWLIB_ID id;
XtPointer client_data;
{
+#ifdef USE_MOTIF
+ ++popup_activated_flag;
+#else
popup_activated_flag = 1;
+#endif
+}
+
+/* This callback is invoked when a dialog or menu is finished being
+ used and has been unposted. */
+
+static void
+popup_deactivate_callback (widget, id, client_data)
+ Widget widget;
+ LWLIB_ID id;
+ XtPointer client_data;
+{
+#ifdef USE_MOTIF
+ --popup_activated_flag;
+#else
+ popup_activated_flag = 0;
+#endif
}
/* Lwlib callback called when menu items are highlighted/unhighlighted
}
}
-/* This callback is invoked when a dialog or menu is finished being
- used and has been unposted. */
-
-static void
-popup_deactivate_callback (widget, id, client_data)
- Widget widget;
- LWLIB_ID id;
- XtPointer client_data;
-{
- popup_activated_flag = 0;
-}
-
/* Allocate a widget_value, blocking input. */
widget_value *