]> Dogcows Code - chaz/openbox/commitdiff
make keypad enter do the same thing as return
authorDana Jansens <danakj@orodu.net>
Fri, 26 Mar 2010 02:17:05 +0000 (22:17 -0400)
committerDana Jansens <danakj@orodu.net>
Fri, 26 Mar 2010 02:18:37 +0000 (22:18 -0400)
openbox/actions/cyclewindows.c
openbox/actions/desktop.c
openbox/actions/directionalwindows.c
openbox/event.c
openbox/moveresize.c
openbox/prompt.c

index 6d852fdf8418ceafa65cc1cd06595e1f8d103074..6bd965773c20c92ac532e3777c86b4e64b612cb1 100644 (file)
@@ -195,7 +195,7 @@ static gboolean i_input_func(guint initial_state,
         }
 
         /* There were no modifiers and they pressed enter */
-        else if (sym == XK_Return && !initial_state) {
+        else if ((sym == XK_Return || sym == XK_KP_Enter) && !initial_state) {
             o->cancel = FALSE;
             o->state = e->xkey.state;
             return FALSE;
index cc0d96538cba42ff7b41ffa56aa85fb8350df9a5..04b0bdd5f26687cd3703a0695e0aede722bea30c 100644 (file)
@@ -327,7 +327,7 @@ static gboolean i_input_func(guint initial_state,
             return FALSE;
 
         /* There were no modifiers and they pressed enter */
-        else if (sym == XK_Return && !initial_state)
+        else if ((sym == XK_Return || sym == XK_KP_Enter) && !initial_state)
             return FALSE;
     }
     /* They released the modifiers */
index d67c3ef4466d6174c83f1dd7f26c01a119a19dfe..602e7edc33fb1dc26b67fc5fe28fc8335b5d64cc 100644 (file)
@@ -278,7 +278,7 @@ static gboolean i_input_func(guint initial_state,
         }
 
         /* There were no modifiers and they pressed enter */
-        else if (sym == XK_Return && !initial_state) {
+        else if ((sym == XK_Return || sym == XK_KP_Enter) && !initial_state) {
             end_cycle(FALSE, e->xkey.state, options);
             return FALSE;
         }
index b3cdf4dc2a7997e2b892c1b2b31c337a86760db0..d63ae2b33777dbad01c165ce923fc77bd3c29245 100644 (file)
@@ -1882,7 +1882,7 @@ static gboolean event_handle_menu_input(XEvent *ev)
                 ret = TRUE;
             }
 
-            else if (sym == XK_Return) {
+            else if (sym == XK_Return || sym == XK_KP_Enter) {
                 frame->press_doexec = TRUE;
                 ret = TRUE;
             }
index 6dcadd66cbf3c0d26f42567e6dfcef7723af592d..466d8662a1d92e61cdd852386ef1fe992e677be0 100644 (file)
@@ -916,7 +916,7 @@ gboolean moveresize_event(XEvent *e)
         if (sym == XK_Escape) {
             moveresize_end(TRUE);
             used = TRUE;
-        } else if (sym == XK_Return) {
+        } else if (sym == XK_Return || sym == XK_KP_Enter) {
             moveresize_end(FALSE);
             used = TRUE;
         } else if (sym == XK_Right || sym == XK_Left ||
index 6df991a4af0dc9ad72de02c33f2616cd1895dc67..3c5de401812327229d8b46b52747db1d21e97391 100644 (file)
@@ -540,7 +540,7 @@ gboolean prompt_key_event(ObPrompt *self, XEvent *e)
 
     if (sym == XK_Escape)
         prompt_cancel(self);
-    else if (sym == XK_Return || sym == XK_space)
+    else if (sym == XK_Return || sym == XK_KP_Enter || sym == XK_space)
         prompt_run_callback(self, self->focus->result);
     else if (sym == XK_Tab || sym == XK_Left || sym == XK_Right) {
         gint i;
This page took 0.030408 seconds and 4 git commands to generate.