summaryrefslogtreecommitdiff
path: root/openbox/moveresize.c
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2007-07-26 22:05:53 -0400
committerDana Jansens <danakj@orodu.net>2008-01-20 01:36:55 -0500
commit759e9f58a8cc02b78bc85b4454f133544e3ac36e (patch)
tree9bd7220b7df84482ad8b580d55e3287843b20ce2 /openbox/moveresize.c
parent1aac72bc4cfffdd816347d305624b15d0ae2112e (diff)
change openbox to use the libotk's keyboard.[ch] stuff instead of the old modkeys.[ch] and some of translate.[ch]
Diffstat (limited to 'openbox/moveresize.c')
-rw-r--r--openbox/moveresize.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/openbox/moveresize.c b/openbox/moveresize.c
index 776f37cd..38963dfc 100644
--- a/openbox/moveresize.c
+++ b/openbox/moveresize.c
@@ -24,7 +24,6 @@
#include "frame.h"
#include "openbox.h"
#include "resist.h"
-#include "modkeys.h"
#include "popup.h"
#include "moveresize.h"
#include "config.h"
@@ -34,6 +33,7 @@
#include "render/theme.h"
#include "obt/display.h"
#include "obt/prop.h"
+#include "obt/keyboard.h"
#include <X11/Xlib.h>
#include <glib.h>
@@ -603,7 +603,7 @@ static void move_with_keys(gint keycode, gint state)
gint dist = 0;
/* shift means jump to edge */
- if (state & modkeys_key_to_mask(OB_MODKEY_KEY_SHIFT)) {
+ if (state & obt_keyboard_modkey_to_modmask(OBT_KEYBOARD_MODKEY_SHIFT)) {
gint x, y;
ObDirection dir;
@@ -621,8 +621,11 @@ static void move_with_keys(gint keycode, gint state)
dy = y - moveresize_client->area.y;
} else {
/* control means fine grained */
- if (state & modkeys_key_to_mask(OB_MODKEY_KEY_CONTROL))
+ if (state &
+ obt_keyboard_modkey_to_modmask(OBT_KEYBOARD_MODKEY_CONTROL))
+ {
dist = 1;
+ }
else
dist = KEY_DIST;
@@ -703,7 +706,7 @@ static void resize_with_keys(gint keycode, gint state)
}
/* shift means jump to edge */
- if (state & modkeys_key_to_mask(OB_MODKEY_KEY_SHIFT)) {
+ if (state & obt_keyboard_modkey_to_modmask(OBT_KEYBOARD_MODKEY_SHIFT)) {
gint x, y, w, h;
if (keycode == ob_keycode(OB_KEY_RIGHT))
@@ -728,7 +731,9 @@ static void resize_with_keys(gint keycode, gint state)
distw = moveresize_client->size_inc.width;
resist = 1;
}
- else if (state & modkeys_key_to_mask(OB_MODKEY_KEY_CONTROL)) {
+ else if (state &
+ obt_keyboard_modkey_to_modmask(OBT_KEYBOARD_MODKEY_CONTROL))
+ {
distw = 1;
resist = 1;
}
@@ -740,7 +745,9 @@ static void resize_with_keys(gint keycode, gint state)
disth = moveresize_client->size_inc.height;
resist = 1;
}
- else if (state & modkeys_key_to_mask(OB_MODKEY_KEY_CONTROL)) {
+ else if (state &
+ obt_keyboard_modkey_to_modmask(OBT_KEYBOARD_MODKEY_CONTROL))
+ {
disth = 1;
resist = 1;
}