summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnselm R. Garbe <arg@suckless.org>2007-06-06 11:17:56 +0200
committerAnselm R. Garbe <arg@suckless.org>2007-06-06 11:17:56 +0200
commit4bf3b019535da3aa14cfccebd65ea726cbd15862 (patch)
treebfbb9877a5eb386f3d7e8870aa97edf7bbc00cab
parentuncommented creatnotify (diff)
downloaddwm-4bf3b019535da3aa14cfccebd65ea726cbd15862.tar.gz
dwm-4bf3b019535da3aa14cfccebd65ea726cbd15862.zip
I change the style of init somewhat, init as early as possible.
Diffstat (limited to '')
-rw-r--r--main.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/main.c b/main.c
index 471cfc2..d72f13d 100644
--- a/main.c
+++ b/main.c
@@ -16,7 +16,9 @@
16 16
17char stext[256]; 17char stext[256];
18int screen, sx, sy, sw, sh, wax, way, waw, wah; 18int screen, sx, sy, sw, sh, wax, way, waw, wah;
19unsigned int bh, bpos, ntags, numlockmask; 19unsigned int bh, ntags;
20unsigned int bpos = BARPOS;
21unsigned int numlockmask = 0;
20Atom wmatom[WMLast], netatom[NetLast]; 22Atom wmatom[WMLast], netatom[NetLast];
21Bool *seltag; 23Bool *seltag;
22Bool selscreen = True; 24Bool selscreen = True;
@@ -149,7 +151,6 @@ setup(void) {
149 cursor[CurResize] = XCreateFontCursor(dpy, XC_sizing); 151 cursor[CurResize] = XCreateFontCursor(dpy, XC_sizing);
150 cursor[CurMove] = XCreateFontCursor(dpy, XC_fleur); 152 cursor[CurMove] = XCreateFontCursor(dpy, XC_fleur);
151 /* init modifier map */ 153 /* init modifier map */
152 numlockmask = 0;
153 modmap = XGetModifierMapping(dpy); 154 modmap = XGetModifierMapping(dpy);
154 for (i = 0; i < 8; i++) 155 for (i = 0; i < 8; i++)
155 for (j = 0; j < modmap->max_keypermod; j++) { 156 for (j = 0; j < modmap->max_keypermod; j++) {
@@ -191,7 +192,6 @@ setup(void) {
191 DefaultDepth(dpy, screen), CopyFromParent, DefaultVisual(dpy, screen), 192 DefaultDepth(dpy, screen), CopyFromParent, DefaultVisual(dpy, screen),
192 CWOverrideRedirect | CWBackPixmap | CWEventMask, &wa); 193 CWOverrideRedirect | CWBackPixmap | CWEventMask, &wa);
193 XDefineCursor(dpy, barwin, cursor[CurNormal]); 194 XDefineCursor(dpy, barwin, cursor[CurNormal]);
194 bpos = BARPOS;
195 updatebarpos(); 195 updatebarpos();
196 XMapRaised(dpy, barwin); 196 XMapRaised(dpy, barwin);
197 strcpy(stext, "dwm-"VERSION); 197 strcpy(stext, "dwm-"VERSION);