]> Dogcows Code - chaz/openbox/blobdiff - openbox/event.c
make binding fallback for mouse clicks less restrictive. if you dont have a binding...
[chaz/openbox] / openbox / event.c
index 8f21120248af2e5d6ee7f8eb0e5e7208990cbd2d..bf2fd932cf1f68e2ab90888cb627743641560b73 100644 (file)
@@ -772,7 +772,8 @@ static void event_handle_client(ObClient *client, XEvent *e)
         {
             /* use where the press occured */
             con = frame_context(client, e->xbutton.window, px, py);
-            con = mouse_button_frame_context(con, e->xbutton.button);
+            con = mouse_button_frame_context(con, e->xbutton.button,
+                                             e->xbutton.state);
 
             if (e->type == ButtonRelease && e->xbutton.button == pb)
                 pb = 0, px = py = -1;
@@ -1482,8 +1483,11 @@ static gboolean event_handle_menu_keyboard(XEvent *ev)
         ret = FALSE;
 
     else if (keycode == ob_keycode(OB_KEY_ESCAPE) && state == 0) {
-        /* Escape closes the active menu */
-        menu_frame_hide(frame);
+        /* Escape goes to the parent menu or closes the last one */
+        if (frame->parent)
+            menu_frame_select(frame, NULL, TRUE);
+        else
+            menu_frame_hide_all();
     }
 
     else if (keycode == ob_keycode(OB_KEY_RETURN) && (state == 0 ||
This page took 0.020938 seconds and 4 git commands to generate.