summary refs log tree commit diff
path: root/calmwm.h
diff options
context:
space:
mode:
authorokan <okan>2015-11-12 18:26:41 +0000
committerokan <okan>2015-11-12 18:26:41 +0000
commit9a48836ceb40313cd12c05781d57f291401de7b0 (patch)
tree9c7894f80ec83b915bc3eef072c8154122510814 /calmwm.h
parenta2c066e447f8c3f754cc5559066b09f80e4c148e (diff)
downloadcwm-9a48836ceb40313cd12c05781d57f291401de7b0.tar.gz
cwm-9a48836ceb40313cd12c05781d57f291401de7b0.tar.xz
cwm-9a48836ceb40313cd12c05781d57f291401de7b0.zip
Move kb pointer movement out of the kbfunc_client_moveresize since it's
got nothing to do with clients, thus doing flags work causes lots of
waste and almost useless jumpy pointer movements; while here, split out
move and resize since they share almost no code, just like mouse client
move/resize; factor out amount and factor. Still wonder why this is
here, but it works now.
Diffstat (limited to 'calmwm.h')
-rw-r--r--calmwm.h21
1 files changed, 10 insertions, 11 deletions
diff --git a/calmwm.h b/calmwm.h
index cf7a194..ddc0a4e 100644
--- a/calmwm.h
+++ b/calmwm.h
@@ -50,15 +50,13 @@
 #define KEYMASK		(KeyPressMask | ExposureMask)
 #define IGNOREMODMASK	(LockMask | Mod2Mask | 0x2000)
 
-/* kb movement */
-#define CWM_MOVE		0x0001
-#define CWM_RESIZE		0x0002
-#define CWM_PTRMOVE		0x0004
-#define CWM_BIGMOVE		0x0008
-#define CWM_UP			0x0010
-#define CWM_DOWN		0x0020
-#define CWM_LEFT		0x0040
-#define CWM_RIGHT		0x0080
+/* direction/amount */
+#define CWM_UP			0x0001
+#define CWM_DOWN		0x0002
+#define CWM_LEFT		0x0004
+#define CWM_RIGHT		0x0008
+#define CWM_BIGAMOUNT		0x0010
+#define DIRECTIONMASK	(CWM_UP | CWM_DOWN | CWM_LEFT | CWM_RIGHT)
 
 #define CWM_CLIENT_CYCLE	0x0001
 #define CWM_CLIENT_RCYCLE	0x0002
@@ -475,14 +473,14 @@ void			 kbfunc_client_grouptoggle(struct client_ctx *,
 void			 kbfunc_client_hide(struct client_ctx *, union arg *);
 void			 kbfunc_client_label(struct client_ctx *, union arg *);
 void			 kbfunc_client_lower(struct client_ctx *, union arg *);
-void			 kbfunc_client_moveresize(struct client_ctx *,
-			     union arg *);
+void			 kbfunc_client_move(struct client_ctx *, union arg *);
 void			 kbfunc_client_movetogroup(struct client_ctx *,
 			     union arg *);
 void			 kbfunc_client_nogroup(struct client_ctx *,
 			     union arg *);
 void			 kbfunc_client_raise(struct client_ctx *, union arg *);
 void			 kbfunc_client_rcycle(struct client_ctx *, union arg *);
+void			 kbfunc_client_resize(struct client_ctx *, union arg *);
 void 			 kbfunc_client_tile(struct client_ctx *, union arg *);
 void			 kbfunc_client_toggle_freeze(struct client_ctx *,
     			     union arg *);
@@ -505,6 +503,7 @@ void			 kbfunc_menu_client(struct client_ctx *, union arg *);
 void			 kbfunc_menu_cmd(struct client_ctx *, union arg *);
 void			 kbfunc_menu_group(struct client_ctx *, union arg *);
 void			 kbfunc_menu_ssh(struct client_ctx *, union arg *);
+void			 kbfunc_ptrmove(struct client_ctx *, union arg *);
 
 void			 mousefunc_client_move(struct client_ctx *,
     			    union arg *);