From: Miles Bader Date: Thu, 4 Jul 1996 05:46:24 +0000 (+0000) Subject: (lw_motif_menu_related_event_p): A predicate to identify keyboard events X-Git-Tag: emacs-19.34~260 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=7f76dcc0ad1eb1f58465676ccaa3b02f362619fc;p=emacs.git (lw_motif_menu_related_event_p): A predicate to identify keyboard events intended only for menus. --- diff --git a/lwlib/lwlib-Xm.c b/lwlib/lwlib-Xm.c index 57e4b4a2ca5..5df98c1d684 100644 --- a/lwlib/lwlib-Xm.c +++ b/lwlib/lwlib-Xm.c @@ -118,6 +118,18 @@ first_child (widget) return ((CompositeWidget)widget)->composite.children [0]; } +Boolean +lw_motif_menu_related_event_p (event) + XEvent event; +{ + Widget widget = XtWindowToWidget (event.xkey.display,event.xkey.window); + WidgetClass class = XtClass (widget); + return + class == xmMainWindowWidgetClass + || class == xmRowColumnWidgetClass + || class == xmMenuShellWidgetClass; +} + Boolean lw_motif_widget_p (widget) Widget widget;