about summary refs log tree commit diff
path: root/calmwm.h
diff options
context:
space:
mode:
authorokan <okan>2013-05-19 17:02:04 +0000
committerokan <okan>2013-05-19 17:02:04 +0000
commit01bfdd7b42834de62e66b57b15145fe483cabdd6 (patch)
tree95d5dacd11bbf5d5a1cbe49022c635020fc8be86 /calmwm.h
parent3253f5a4a1b849ea51594eccff2f6974e578b4af (diff)
downloadcwm-01bfdd7b42834de62e66b57b15145fe483cabdd6.tar.gz
cwm-01bfdd7b42834de62e66b57b15145fe483cabdd6.tar.xz
cwm-01bfdd7b42834de62e66b57b15145fe483cabdd6.zip
use XGetWMProtocols and simplify WM_PROTOCOL handling
Diffstat (limited to 'calmwm.h')
-rw-r--r--calmwm.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/calmwm.h b/calmwm.h
index 055496a..033ed5a 100644
--- a/calmwm.h
+++ b/calmwm.h
@@ -121,6 +121,11 @@ struct winname {
 };
 TAILQ_HEAD(winname_q, winname);
 
+enum wm_protocols {
+	_WM_DELETE_WINDOW	= 0x0001,
+	_WM_TAKE_FOCUS		= 0x0002,
+};
+
 struct client_ctx {
 	TAILQ_ENTRY(client_ctx) entry;
 	TAILQ_ENTRY(client_ctx) group_entry;
@@ -147,9 +152,7 @@ struct client_ctx {
 		int		 x;	/* x position */
 		int		 y;	/* y position */
 	} ptr;
-#define CLIENT_PROTO_DELETE		 0x0001
-#define CLIENT_PROTO_TAKEFOCUS		 0x0002
-	int			 xproto;
+	enum wm_protocols	 xproto;
 #define CLIENT_HIDDEN			0x0001
 #define CLIENT_IGNORE			0x0002
 #define CLIENT_VMAXIMIZED		0x0004