summary refs log tree commit diff
path: root/xutil.c
diff options
context:
space:
mode:
authorokan <okan>2013-04-14 16:13:17 +0000
committerokan <okan>2013-04-14 16:13:17 +0000
commit16ed8bf8e4f561049b732b326f3d0ee475fe13f6 (patch)
tree69faebffc8e2511edbf4bdca1d32e2a78eeb1e9e /xutil.c
parentf3dfc4968cee2080cfa4a4f24f0977b962aa367d (diff)
downloadcwm-16ed8bf8e4f561049b732b326f3d0ee475fe13f6.tar.gz
cwm-16ed8bf8e4f561049b732b326f3d0ee475fe13f6.tar.xz
cwm-16ed8bf8e4f561049b732b326f3d0ee475fe13f6.zip
only a window is required to set WM_STATE. also un-confuse xu_ptr_getpos
by using 'win' instead of 'rootwin' so as not to imply only the root
window is queried, rather any window.
Diffstat (limited to 'xutil.c')
-rw-r--r--xutil.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/xutil.c b/xutil.c
index 3605e71..a663150 100644
--- a/xutil.c
+++ b/xutil.c
@@ -72,13 +72,13 @@ xu_btn_ungrab(Window win, int mask, u_int btn)
 }
 
 void
-xu_ptr_getpos(Window rootwin, int *x, int *y)
+xu_ptr_getpos(Window win, int *x, int *y)
 {
 	Window	 w0, w1;
 	int	 tmp0, tmp1;
 	u_int	 tmp2;
 
-	XQueryPointer(X_Dpy, rootwin, &w0, &w1, &tmp0, &tmp1, x, y, &tmp2);
+	XQueryPointer(X_Dpy, win, &w0, &w1, &tmp0, &tmp1, x, y, &tmp2);
 }
 
 void
@@ -203,11 +203,11 @@ xu_getstrprop(Window win, Atom atm, char **text) {
 }
 
 int
-xu_getstate(struct client_ctx *cc, int *state)
+xu_getstate(Window win, int *state)
 {
 	long	*p = NULL;
 
-	if (xu_getprop(cc->win, cwmh[WM_STATE].atom, cwmh[WM_STATE].atom, 2L,
+	if (xu_getprop(win, cwmh[WM_STATE].atom, cwmh[WM_STATE].atom, 2L,
 	    (u_char **)&p) <= 0)
 		return (-1);