diff options
Diffstat (limited to 'dwm.c')
| -rw-r--r-- | dwm.c | 24 |
1 files changed, 12 insertions, 12 deletions
| @@ -556,8 +556,8 @@ clientmessage(XEvent *e) { | |||
| 556 | } | 556 | } |
| 557 | else if(cme->message_type == netatom[NetActiveWindow]) { | 557 | else if(cme->message_type == netatom[NetActiveWindow]) { |
| 558 | if(!ISVISIBLE(c)) { | 558 | if(!ISVISIBLE(c)) { |
| 559 | c->mon->seltags ^= 1; | 559 | c->mon->seltags ^= 1; |
| 560 | c->mon->tagset[c->mon->seltags] = c->tags; | 560 | c->mon->tagset[c->mon->seltags] = c->tags; |
| 561 | } | 561 | } |
| 562 | pop(c); | 562 | pop(c); |
| 563 | } | 563 | } |
| @@ -1213,7 +1213,7 @@ movemouse(const Arg *arg) { | |||
| 1213 | return; | 1213 | return; |
| 1214 | do { | 1214 | do { |
| 1215 | XMaskEvent(dpy, MOUSEMASK|ExposureMask|SubstructureRedirectMask, &ev); | 1215 | XMaskEvent(dpy, MOUSEMASK|ExposureMask|SubstructureRedirectMask, &ev); |
| 1216 | switch (ev.type) { | 1216 | switch(ev.type) { |
| 1217 | case ConfigureRequest: | 1217 | case ConfigureRequest: |
| 1218 | case Expose: | 1218 | case Expose: |
| 1219 | case MapRequest: | 1219 | case MapRequest: |
| @@ -1274,7 +1274,7 @@ propertynotify(XEvent *e) { | |||
| 1274 | else if(ev->state == PropertyDelete) | 1274 | else if(ev->state == PropertyDelete) |
| 1275 | return; /* ignore */ | 1275 | return; /* ignore */ |
| 1276 | else if((c = wintoclient(ev->window))) { | 1276 | else if((c = wintoclient(ev->window))) { |
| 1277 | switch (ev->atom) { | 1277 | switch(ev->atom) { |
| 1278 | default: break; | 1278 | default: break; |
| 1279 | case XA_WM_TRANSIENT_FOR: | 1279 | case XA_WM_TRANSIENT_FOR: |
| 1280 | if(!c->isfloating && (XGetTransientForHint(dpy, c->win, &trans)) && | 1280 | if(!c->isfloating && (XGetTransientForHint(dpy, c->win, &trans)) && |
| @@ -1542,8 +1542,8 @@ setup(void) { | |||
| 1542 | wmatom[WMProtocols] = XInternAtom(dpy, "WM_PROTOCOLS", False); | 1542 | wmatom[WMProtocols] = XInternAtom(dpy, "WM_PROTOCOLS", False); |
| 1543 | wmatom[WMDelete] = XInternAtom(dpy, "WM_DELETE_WINDOW", False); | 1543 | wmatom[WMDelete] = XInternAtom(dpy, "WM_DELETE_WINDOW", False); |
| 1544 | wmatom[WMState] = XInternAtom(dpy, "WM_STATE", False); | 1544 | wmatom[WMState] = XInternAtom(dpy, "WM_STATE", False); |
| 1545 | netatom[NetActiveWindow] = XInternAtom(dpy, "_NET_ACTIVE_WINDOW", False); | ||
| 1546 | wmatom[WMTakeFocus] = XInternAtom(dpy, "WM_TAKE_FOCUS", False); | 1545 | wmatom[WMTakeFocus] = XInternAtom(dpy, "WM_TAKE_FOCUS", False); |
| 1546 | netatom[NetActiveWindow] = XInternAtom(dpy, "_NET_ACTIVE_WINDOW", False); | ||
| 1547 | netatom[NetSupported] = XInternAtom(dpy, "_NET_SUPPORTED", False); | 1547 | netatom[NetSupported] = XInternAtom(dpy, "_NET_SUPPORTED", False); |
| 1548 | netatom[NetWMName] = XInternAtom(dpy, "_NET_WM_NAME", False); | 1548 | netatom[NetWMName] = XInternAtom(dpy, "_NET_WM_NAME", False); |
| 1549 | netatom[NetWMState] = XInternAtom(dpy, "_NET_WM_STATE", False); | 1549 | netatom[NetWMState] = XInternAtom(dpy, "_NET_WM_STATE", False); |
| @@ -1612,7 +1612,7 @@ spawn(const Arg *arg) { | |||
| 1612 | execvp(((char **)arg->v)[0], (char **)arg->v); | 1612 | execvp(((char **)arg->v)[0], (char **)arg->v); |
| 1613 | fprintf(stderr, "dwm: execvp %s", ((char **)arg->v)[0]); | 1613 | fprintf(stderr, "dwm: execvp %s", ((char **)arg->v)[0]); |
| 1614 | perror(" failed"); | 1614 | perror(" failed"); |
| 1615 | exit(0); | 1615 | exit(EXIT_SUCCESS); |
| 1616 | } | 1616 | } |
| 1617 | } | 1617 | } |
| 1618 | 1618 | ||
| @@ -1760,11 +1760,11 @@ unmapnotify(XEvent *e) { | |||
| 1760 | void | 1760 | void |
| 1761 | updatebars(void) { | 1761 | updatebars(void) { |
| 1762 | Monitor *m; | 1762 | Monitor *m; |
| 1763 | XSetWindowAttributes wa; | 1763 | XSetWindowAttributes wa = { |
| 1764 | 1764 | .override_redirect = True, | |
| 1765 | wa.override_redirect = True; | 1765 | .background_pixmap = ParentRelative, |
| 1766 | wa.background_pixmap = ParentRelative; | 1766 | .event_mask = ButtonPressMask|ExposureMask |
| 1767 | wa.event_mask = ButtonPressMask|ExposureMask; | 1767 | }; |
| 1768 | for(m = mons; m; m = m->next) { | 1768 | for(m = mons; m; m = m->next) { |
| 1769 | m->barwin = XCreateWindow(dpy, root, m->wx, m->by, m->ww, bh, 0, DefaultDepth(dpy, screen), | 1769 | m->barwin = XCreateWindow(dpy, root, m->wx, m->by, m->ww, bh, 0, DefaultDepth(dpy, screen), |
| 1770 | CopyFromParent, DefaultVisual(dpy, screen), | 1770 | CopyFromParent, DefaultVisual(dpy, screen), |
| @@ -2069,5 +2069,5 @@ main(int argc, char *argv[]) { | |||
| 2069 | run(); | 2069 | run(); |
| 2070 | cleanup(); | 2070 | cleanup(); |
| 2071 | XCloseDisplay(dpy); | 2071 | XCloseDisplay(dpy); |
| 2072 | return 0; | 2072 | return EXIT_SUCCESS; |
| 2073 | } | 2073 | } |
