summaryrefslogtreecommitdiff
path: root/lwlib
diff options
context:
space:
mode:
authorGerd Moellmann <gerd@gnu.org>2000-12-07 12:33:32 +0000
committerGerd Moellmann <gerd@gnu.org>2000-12-07 12:33:32 +0000
commit579eb16892d720948185f9697b548a3d3b4e3aac (patch)
tree2e204aa9ee66b9ea6811837bc1ac91258781f7e5 /lwlib
parente82a2fbf23fd3c7b43e8ce78ce410c32c5701a21 (diff)
downloademacs-579eb16892d720948185f9697b548a3d3b4e3aac.tar.gz
(xm_arm_callback): Fix last change.
Diffstat (limited to 'lwlib')
-rw-r--r--lwlib/lwlib-Xm.c27
1 files changed, 12 insertions, 15 deletions
diff --git a/lwlib/lwlib-Xm.c b/lwlib/lwlib-Xm.c
index 4a3f097a867..2cbcba4c1a0 100644
--- a/lwlib/lwlib-Xm.c
+++ b/lwlib/lwlib-Xm.c
@@ -265,26 +265,23 @@ xm_arm_callback (w, client_data, call_data)
widget_value *wv = (widget_value *) client_data;
widget_instance *instance;
- /* During the pretest of 21.1, there was a case where this callback
- was called with a null widget on hpux 10.2. I think that's
- likely a bug in the Motif lib there. */
- if (w != None)
+ /* Get the id of the menu bar or popup menu this widget is in. */
+ while (w != None)
{
- /* Get the id of the menu bar or popup menu this widget is in. */
- while (1)
+ if (XmIsRowColumn (w))
{
- if (XmIsRowColumn (w))
- {
- unsigned char type = 0xff;
-
- XtVaGetValues (w, XmNrowColumnType, &type, NULL);
- if (type == XmMENU_BAR || type == XmMENU_POPUP)
- break;
- }
+ unsigned char type = 0xff;
- w = XtParent (w);
+ XtVaGetValues (w, XmNrowColumnType, &type, NULL);
+ if (type == XmMENU_BAR || type == XmMENU_POPUP)
+ break;
}
+ w = XtParent (w);
+ }
+
+ if (w != None)
+ {
instance = lw_get_widget_instance (w);
if (instance && instance->info->highlight_cb)
{