I change the style of init somewhat, init as early as possible. 4bf3b019
Anselm R. Garbe · 2007-06-06 11:17 1 file(s) · +3 −3
main.c +3 −3
16 16
17 17
char stext[256];
18 18
int screen, sx, sy, sw, sh, wax, way, waw, wah;
19 -
unsigned int bh, bpos, ntags, numlockmask;
19 +
unsigned int bh, ntags;
20 +
unsigned int bpos = BARPOS;
21 +
unsigned int numlockmask = 0;
20 22
Atom wmatom[WMLast], netatom[NetLast];
21 23
Bool *seltag;
22 24
Bool selscreen = True;
149 151
	cursor[CurResize] = XCreateFontCursor(dpy, XC_sizing);
150 152
	cursor[CurMove] = XCreateFontCursor(dpy, XC_fleur);
151 153
	/* init modifier map */
152 -
	numlockmask = 0;
153 154
	modmap = XGetModifierMapping(dpy);
154 155
	for (i = 0; i < 8; i++)
155 156
		for (j = 0; j < modmap->max_keypermod; j++) {
191 192
			DefaultDepth(dpy, screen), CopyFromParent, DefaultVisual(dpy, screen),
192 193
			CWOverrideRedirect | CWBackPixmap | CWEventMask, &wa);
193 194
	XDefineCursor(dpy, barwin, cursor[CurNormal]);
194 -
	bpos = BARPOS;
195 195
	updatebarpos();
196 196
	XMapRaised(dpy, barwin);
197 197
	strcpy(stext, "dwm-"VERSION);