diff options
author | rafa_99 <raroma09@gmail.com> | 2022-07-18 10:03:36 +0100 |
---|---|---|
committer | rafa_99 <raroma09@gmail.com> | 2022-07-18 10:03:36 +0100 |
commit | 54c07febcffb4685d0309fbaedc86a7fbbee83d8 (patch) | |
tree | 81555976ab1c205a8dd595fadaeb9e8e29ab865f /dwm.c | |
parent | 1a3026499753ea68cfe078f4fb47ff739ac33708 (diff) |
Revert "Fade inactive patch"
This reverts commit 8cde91d76ee62d3347edc72047f1e5277feacb4b.
Diffstat (limited to 'dwm.c')
-rw-r--r-- | dwm.c | 27 |
1 files changed, 1 insertions, 26 deletions
@@ -68,7 +68,7 @@ enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */ enum { SchemeNorm, SchemeSel }; /* color schemes */ enum { NetSupported, NetWMName, NetWMState, NetWMCheck, NetWMFullscreen, NetActiveWindow, NetWMWindowType, - NetWMWindowTypeDialog, NetClientList, NetWMWindowsOpacity, NetLast }; /* EWMH atoms */ + NetWMWindowTypeDialog, NetClientList, NetLast }; /* EWMH atoms */ enum { WMProtocols, WMDelete, WMState, WMTakeFocus, WMLast }; /* default atoms */ enum { ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, ClkRootWin, ClkLast }; /* clicks */ @@ -200,7 +200,6 @@ static void moveresize(const Arg *arg); static void motionnotify(XEvent *e); static void movemouse(const Arg *arg); static Client *nexttiled(Client *c); -static void opacity(Client *c, double opacity); static void pop(Client *c); static void propertynotify(XEvent *e); static void quit(const Arg *arg); @@ -231,7 +230,6 @@ static void tagtoleft(const Arg *arg); static void tagtoright(const Arg *arg); static void togglebar(const Arg *arg); static void togglefloating(const Arg *arg); -static void toggleopacity(const Arg *arg); static void toggletag(const Arg *arg); static void toggleview(const Arg *arg); static void unfocus(Client *c, int setfocus); @@ -898,7 +896,6 @@ focus(Client *c) grabbuttons(c, 1); XSetWindowBorder(dpy, c->win, scheme[SchemeSel][ColBorder].pixel); setfocus(c); - opacity(c, activeopacity); } else { XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime); XDeleteProperty(dpy, root, netatom[NetActiveWindow]); @@ -1371,18 +1368,6 @@ nexttiled(Client *c) } void -opacity(Client *c, double opacity) -{ - if(bUseOpacity && opacity > 0 && opacity < 1) { - unsigned long real_opacity[] = { opacity * 0xffffffff }; - XChangeProperty(dpy, c->win, netatom[NetWMWindowsOpacity], XA_CARDINAL, - 32, PropModeReplace, (unsigned char *)real_opacity, - 1); - } else - XDeleteProperty(dpy, c->win, netatom[NetWMWindowsOpacity]); -} - -void pop(Client *c) { detach(c); @@ -1762,7 +1747,6 @@ setup(void) netatom[NetWMWindowType] = XInternAtom(dpy, "_NET_WM_WINDOW_TYPE", False); netatom[NetWMWindowTypeDialog] = XInternAtom(dpy, "_NET_WM_WINDOW_TYPE_DIALOG", False); netatom[NetClientList] = XInternAtom(dpy, "_NET_CLIENT_LIST", False); - netatom[NetWMWindowsOpacity] = XInternAtom(dpy, "_NET_WM_WINDOW_OPACITY", False); /* init cursors */ cursor[CurNormal] = drw_cur_create(drw, XC_left_ptr); cursor[CurResize] = drw_cur_create(drw, XC_sizing); @@ -1905,14 +1889,6 @@ togglefloating(const Arg *arg) } void -toggleopacity(const Arg *arg) { - bUseOpacity = !bUseOpacity; - for (Monitor* m = mons; m; m = m->next) - for (Client* c = m->clients; c; c = c->next) - opacity(c, (bUseOpacity && c != selmon->sel) ? inactiveopacity : activeopacity); -} - -void toggletag(const Arg *arg) { unsigned int newtags; @@ -1945,7 +1921,6 @@ unfocus(Client *c, int setfocus) if (!c) return; grabbuttons(c, 0); - opacity(c, inactiveopacity); XSetWindowBorder(dpy, c->win, scheme[SchemeNorm][ColBorder].pixel); if (setfocus) { XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime); |