From c49ef0524db9aad2fdbc3ccca147795eb5de3b59 Mon Sep 17 00:00:00 2001 From: Martin Duquesnoy Date: Tue, 18 Nov 2008 20:49:54 +0100 Subject: [PATCH] Cosmetic & typo --- src/client.c | 6 ++---- src/config.c | 5 +++-- src/draw.c | 1 - src/event.c | 12 +++++++++--- src/infobar.c | 2 ++ src/mouse.c | 10 +++++++--- src/wmfs.c | 2 +- 7 files changed, 24 insertions(+), 14 deletions(-) diff --git a/src/client.c b/src/client.c index eef0f7e..b031167 100644 --- a/src/client.c +++ b/src/client.c @@ -125,8 +125,7 @@ uicb_client_prev(uicb_t cmd) if(c) { client_focus(c); - if(!c->tile) - client_raise(c); + client_raise(c); } arrange(); @@ -150,8 +149,7 @@ uicb_client_next(uicb_t cmd) if(c) { client_focus(c); - if(!c->tile) - client_raise(c); + client_raise(c); } arrange(); diff --git a/src/config.c b/src/config.c index 646f9c2..ff8399d 100644 --- a/src/config.c +++ b/src/config.c @@ -185,6 +185,7 @@ mouse_section(MouseBinding mb[], cfg_t *cfg, int ns) } /** Configuration initialization + * \todo Make functions for all section (tag, client, layout...) */ void init_conf(void) @@ -439,8 +440,8 @@ init_conf(void) } } - /* tag */ - /* if there is no tag in the conf or more than + /* tag + * if there is no tag in the conf or more than * MAXTAG (32) print an error and create only one. */ conf.colors.tagselfg = strdup(var_to_str(cfg_getstr(cfg_tags, "sel_fg"))); diff --git a/src/draw.c b/src/draw.c index 23709f6..d42c77d 100644 --- a/src/draw.c +++ b/src/draw.c @@ -61,7 +61,6 @@ draw_text(Drawable d, int x, int y, char* fg, int pad, char *str) XftDrawDestroy(xftd); - return; } diff --git a/src/event.c b/src/event.c index f36adb1..5f98579 100644 --- a/src/event.c +++ b/src/event.c @@ -239,8 +239,13 @@ grabkeys(void) { uint i, j; KeyCode code; - uint ml[] = {LockMask, numlockmask, scrolllockmask, numlockmask|scrolllockmask, - LockMask|scrolllockmask, LockMask|numlockmask, LockMask|numlockmask|scrolllockmask}; + uint ml[] = {LockMask, + numlockmask, + scrolllockmask, + numlockmask|scrolllockmask, + LockMask|scrolllockmask, + LockMask|numlockmask, + LockMask|numlockmask|scrolllockmask}; XUngrabKey(dpy, AnyKey, AnyModifier, root); for(i = 0; i < conf.nkeybind; ++i) @@ -265,7 +270,8 @@ keypress(XKeyPressedEvent *ev) keysym = XKeycodeToKeysym(dpy, (KeyCode)ev->keycode, 0); for(i = 0; i < conf.nkeybind; ++i) if(keysym == keys[i].keysym - && (keys[i].mod & ~(numlockmask | LockMask)) == (ev->state & ~(numlockmask | LockMask)) + && (keys[i].mod & ~(numlockmask | LockMask | scrolllockmask)) + == (ev->state & ~(numlockmask | LockMask | scrolllockmask)) && keys[i].func) keys[i].func(keys[i].cmd); diff --git a/src/infobar.c b/src/infobar.c index 78286a1..b25f5e7 100644 --- a/src/infobar.c +++ b/src/infobar.c @@ -129,6 +129,8 @@ infobar_draw_taglist(void) return; } +/** Destroy the InfoBar +*/ void infobar_destroy(void) { diff --git a/src/mouse.c b/src/mouse.c index b2e163b..3db3c8e 100644 --- a/src/mouse.c +++ b/src/mouse.c @@ -187,9 +187,13 @@ mouse_grabbuttons(Client *c, Bool focused) int i, j; uint mod = conf.client.mod; uint bl[] = {Button1, Button2, Button3, Button4, Button5}; - uint ml[] = {mod, mod|LockMask, mod|numlockmask, mod|scrolllockmask, - mod|numlockmask|scrolllockmask, mod|LockMask|scrolllockmask, - mod|LockMask|numlockmask,mod|LockMask|numlockmask|scrolllockmask}; + uint ml[] = {mod, mod|LockMask, + mod|numlockmask, + mod|scrolllockmask, + mod|numlockmask|scrolllockmask, + mod|LockMask|scrolllockmask, + mod|LockMask|numlockmask, + mod|LockMask|numlockmask|scrolllockmask}; XUngrabButton(dpy, AnyButton, AnyModifier, c->win); diff --git a/src/wmfs.c b/src/wmfs.c index 2a0cb59..ff25492 100644 --- a/src/wmfs.c +++ b/src/wmfs.c @@ -165,7 +165,7 @@ uicb_quit(uicb_t cmd) return; } -/** Scan if there are window on X +/** Scan if there are windows on X * for manage it */ void