]> Dogcows Code - chaz/openbox/commitdiff
make the timeout apply to releases on menu items too
authorDana Jansens <danakj@orodu.net>
Sun, 28 Sep 2003 09:31:23 +0000 (09:31 +0000)
committerDana Jansens <danakj@orodu.net>
Sun, 28 Sep 2003 09:31:23 +0000 (09:31 +0000)
openbox/event.c

index 6c3d61bbba096ffd6d9d6e1b3f44786e4fe1fb17..14afeabaf8c8df7252714632a54ca1425298f324 100644 (file)
@@ -1183,11 +1183,13 @@ static void event_handle_menu(XEvent *ev)
 
     switch (ev->type) {
     case ButtonRelease:
-        if ((e = menu_entry_frame_under(ev->xbutton.x_root,
-                                        ev->xbutton.y_root)))
-            menu_entry_frame_execute(e, ev->xbutton.state);
-        else if (menu_can_hide)
-            menu_frame_hide_all();
+        if (menu_can_hide) {
+            if ((e = menu_entry_frame_under(ev->xbutton.x_root,
+                                            ev->xbutton.y_root)))
+                menu_entry_frame_execute(e, ev->xbutton.state);
+            else
+                menu_frame_hide_all();
+        }
         break;
     case MotionNotify:
         if ((f = menu_frame_under(ev->xmotion.x_root,
This page took 0.025031 seconds and 4 git commands to generate.