From 4fd30cca079892e19dd55a6d2c568c383edd7b06 Mon Sep 17 00:00:00 2001 From: okan Date: Fri, 10 May 2013 16:32:47 +0000 Subject: more type fixes for mask/button --- calmwm.h | 16 ++++++++-------- conf.c | 4 ++-- xevents.c | 4 ++-- xutil.c | 10 +++++----- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/calmwm.h b/calmwm.h index 729b471..bc46871 100644 --- a/calmwm.h +++ b/calmwm.h @@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: calmwm.h,v 1.195 2013/05/10 15:44:43 okan Exp $ + * $OpenBSD: calmwm.h,v 1.196 2013/05/10 16:32:47 okan Exp $ */ #ifndef _CALMWM_H_ @@ -235,7 +235,7 @@ struct keybinding { TAILQ_ENTRY(keybinding) entry; void (*callback)(struct client_ctx *, union arg *); union arg argument; - int modmask; + u_int modmask; KeySym keysym; int keycode; #define KBFLAG_NEEDCLIENT 0x0001 @@ -247,8 +247,8 @@ TAILQ_HEAD(keybinding_q, keybinding); struct mousebinding { TAILQ_ENTRY(mousebinding) entry; void (*callback)(struct client_ctx *, void *); - int modmask; - int button; + u_int modmask; + u_int button; #define MOUSEBIND_CTX_ROOT 0x0001 #define MOUSEBIND_CTX_WIN 0x0002 int context; @@ -465,11 +465,11 @@ unsigned long xu_getcolor(struct screen_ctx *, char *); int xu_getprop(Window, Atom, Atom, long, u_char **); int xu_get_wm_state(Window, int *); int xu_getstrprop(Window, Atom, char **); -void xu_key_grab(Window, int, KeySym); -void xu_key_ungrab(Window, int, KeySym); +void xu_key_grab(Window, u_int, KeySym); +void xu_key_ungrab(Window, u_int, KeySym); void xu_ptr_getpos(Window, int *, int *); -int xu_ptr_grab(Window, int, Cursor); -int xu_ptr_regrab(int, Cursor); +int xu_ptr_grab(Window, u_int, Cursor); +int xu_ptr_regrab(u_int, Cursor); void xu_ptr_setpos(Window, int, int); void xu_ptr_ungrab(void); void xu_sendmsg(Window, Atom, long); diff --git a/conf.c b/conf.c index ba90add..c2c3bbb 100644 --- a/conf.c +++ b/conf.c @@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: conf.c,v 1.124 2013/05/10 16:05:34 okan Exp $ + * $OpenBSD: conf.c,v 1.125 2013/05/10 16:32:48 okan Exp $ */ #include @@ -627,7 +627,7 @@ void conf_grab_mouse(struct client_ctx *cc) { struct mousebinding *mb; - int button; + u_int button; TAILQ_FOREACH(mb, &Conf.mousebindingq, entry) { if (mb->context != MOUSEBIND_CTX_WIN) diff --git a/xevents.c b/xevents.c index 8582801..006e3c2 100644 --- a/xevents.c +++ b/xevents.c @@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: xevents.c,v 1.74 2013/05/10 16:05:34 okan Exp $ + * $OpenBSD: xevents.c,v 1.75 2013/05/10 16:32:48 okan Exp $ */ /* @@ -277,7 +277,7 @@ xev_handle_keypress(XEvent *ee) struct client_ctx *cc = NULL, fakecc; struct keybinding *kb; KeySym keysym, skeysym; - int modshift; + u_int modshift; keysym = XkbKeycodeToKeysym(X_Dpy, e->keycode, 0, 0); skeysym = XkbKeycodeToKeysym(X_Dpy, e->keycode, 0, 1); diff --git a/xutil.c b/xutil.c index 148e9d7..530a29a 100644 --- a/xutil.c +++ b/xutil.c @@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: xutil.c,v 1.58 2013/05/10 16:05:34 okan Exp $ + * $OpenBSD: xutil.c,v 1.59 2013/05/10 16:32:48 okan Exp $ */ #include @@ -33,7 +33,7 @@ static unsigned int ign_mods[] = { 0, LockMask, Mod2Mask, Mod2Mask | LockMask }; int -xu_ptr_grab(Window win, int mask, Cursor curs) +xu_ptr_grab(Window win, u_int mask, Cursor curs) { return (XGrabPointer(X_Dpy, win, False, mask, GrabModeAsync, GrabModeAsync, @@ -41,7 +41,7 @@ xu_ptr_grab(Window win, int mask, Cursor curs) } int -xu_ptr_regrab(int mask, Cursor curs) +xu_ptr_regrab(u_int mask, Cursor curs) { return (XChangeActivePointerGrab(X_Dpy, mask, curs, CurrentTime) == GrabSuccess ? 0 : -1); @@ -90,7 +90,7 @@ xu_ptr_setpos(Window win, int x, int y) } void -xu_key_grab(Window win, int mask, KeySym keysym) +xu_key_grab(Window win, u_int mask, KeySym keysym) { KeyCode code; u_int i; @@ -106,7 +106,7 @@ xu_key_grab(Window win, int mask, KeySym keysym) } void -xu_key_ungrab(Window win, int mask, KeySym keysym) +xu_key_ungrab(Window win, u_int mask, KeySym keysym) { KeyCode code; u_int i; -- cgit v1.2.3-2-gb3c3