dwm-fakefullscreen-20210515-67d76bd.diff - sites - public wiki contents of suck… | |
git clone git://git.suckless.org/sites | |
Log | |
Files | |
Refs | |
--- | |
dwm-fakefullscreen-20210515-67d76bd.diff (4143B) | |
--- | |
1 From 385141aa77f52836ea395a5a406d50aab89a67c8 Mon Sep 17 00:00:00 2001 | |
2 From: =?UTF-8?q?Tom=20B=C3=B6hmer?= <[email protected]> | |
3 Date: Sat, 15 May 2021 22:24:00 +0200 | |
4 Subject: [PATCH 1/2] Revert "Do not allow focus to drift from fullscreen | |
5 client via focusstack()" | |
6 | |
7 This reverts commit 67d76bdc68102df976177de351f65329d8683064. | |
8 | |
9 The reverted commit conflicts with the functionality of the | |
10 fakefullscreen patch. | |
11 --- | |
12 dwm.c | 2 +- | |
13 1 file changed, 1 insertion(+), 1 deletion(-) | |
14 | |
15 diff --git a/dwm.c b/dwm.c | |
16 index b0b3466..664c527 100644 | |
17 --- a/dwm.c | |
18 +++ b/dwm.c | |
19 @@ -835,7 +835,7 @@ focusstack(const Arg *arg) | |
20 { | |
21 Client *c = NULL, *i; | |
22 | |
23 - if (!selmon->sel || selmon->sel->isfullscreen) | |
24 + if (!selmon->sel) | |
25 return; | |
26 if (arg->i > 0) { | |
27 for (c = selmon->sel->next; c && !ISVISIBLE(c); c = c->… | |
28 -- | |
29 2.31.1 | |
30 | |
31 | |
32 From 05acd5d95400de6efe0d6ec584a5ca20a03f1267 Mon Sep 17 00:00:00 2001 | |
33 From: =?UTF-8?q?Tom=20B=C3=B6hmer?= <[email protected]> | |
34 Date: Sat, 15 May 2021 22:27:19 +0200 | |
35 Subject: [PATCH 2/2] Applied patch dwm-fakefullscreen-20170508-ceac8c9.d… | |
36 | |
37 --- | |
38 dwm.c | 28 ++-------------------------- | |
39 1 file changed, 2 insertions(+), 26 deletions(-) | |
40 | |
41 diff --git a/dwm.c b/dwm.c | |
42 index 664c527..d42b1ee 100644 | |
43 --- a/dwm.c | |
44 +++ b/dwm.c | |
45 @@ -522,7 +522,7 @@ clientmessage(XEvent *e) | |
46 if (cme->data.l[1] == netatom[NetWMFullscreen] | |
47 || cme->data.l[2] == netatom[NetWMFullscreen]) | |
48 setfullscreen(c, (cme->data.l[0] == 1 /* _NET_W… | |
49 - || (cme->data.l[0] == 2 /* _NET_WM_STAT… | |
50 + || cme->data.l[0] == 2 /* _NET_WM_STATE… | |
51 } else if (cme->message_type == netatom[NetActiveWindow]) { | |
52 if (c != selmon->sel && !c->isurgent) | |
53 seturgent(c, 1); | |
54 @@ -552,7 +552,6 @@ void | |
55 configurenotify(XEvent *e) | |
56 { | |
57 Monitor *m; | |
58 - Client *c; | |
59 XConfigureEvent *ev = &e->xconfigure; | |
60 int dirty; | |
61 | |
62 @@ -565,9 +564,6 @@ configurenotify(XEvent *e) | |
63 drw_resize(drw, sw, bh); | |
64 updatebars(); | |
65 for (m = mons; m; m = m->next) { | |
66 - for (c = m->clients; c; c = c->next) | |
67 - if (c->isfullscreen) | |
68 - resizeclient(c, m->mx, … | |
69 XMoveResizeWindow(dpy, m->barwin, m->wx… | |
70 } | |
71 focus(NULL); | |
72 @@ -1144,8 +1140,6 @@ movemouse(const Arg *arg) | |
73 | |
74 if (!(c = selmon->sel)) | |
75 return; | |
76 - if (c->isfullscreen) /* no support moving fullscreen windows by… | |
77 - return; | |
78 restack(selmon); | |
79 ocx = c->x; | |
80 ocy = c->y; | |
81 @@ -1299,8 +1293,6 @@ resizemouse(const Arg *arg) | |
82 | |
83 if (!(c = selmon->sel)) | |
84 return; | |
85 - if (c->isfullscreen) /* no support resizing fullscreen windows … | |
86 - return; | |
87 restack(selmon); | |
88 ocx = c->x; | |
89 ocy = c->y; | |
90 @@ -1477,24 +1469,10 @@ setfullscreen(Client *c, int fullscreen) | |
91 XChangeProperty(dpy, c->win, netatom[NetWMState], XA_AT… | |
92 PropModeReplace, (unsigned char*)&netatom[NetWM… | |
93 c->isfullscreen = 1; | |
94 - c->oldstate = c->isfloating; | |
95 - c->oldbw = c->bw; | |
96 - c->bw = 0; | |
97 - c->isfloating = 1; | |
98 - resizeclient(c, c->mon->mx, c->mon->my, c->mon->mw, c->… | |
99 - XRaiseWindow(dpy, c->win); | |
100 } else if (!fullscreen && c->isfullscreen){ | |
101 XChangeProperty(dpy, c->win, netatom[NetWMState], XA_AT… | |
102 PropModeReplace, (unsigned char*)0, 0); | |
103 c->isfullscreen = 0; | |
104 - c->isfloating = c->oldstate; | |
105 - c->bw = c->oldbw; | |
106 - c->x = c->oldx; | |
107 - c->y = c->oldy; | |
108 - c->w = c->oldw; | |
109 - c->h = c->oldh; | |
110 - resizeclient(c, c->x, c->y, c->w, c->h); | |
111 - arrange(c->mon); | |
112 } | |
113 } | |
114 | |
115 @@ -1619,7 +1597,7 @@ showhide(Client *c) | |
116 if (ISVISIBLE(c)) { | |
117 /* show clients top down */ | |
118 XMoveWindow(dpy, c->win, c->x, c->y); | |
119 - if ((!c->mon->lt[c->mon->sellt]->arrange || c->isfloati… | |
120 + if (!c->mon->lt[c->mon->sellt]->arrange || c->isfloatin… | |
121 resize(c, c->x, c->y, c->w, c->h, 0); | |
122 showhide(c->snext); | |
123 } else { | |
124 @@ -1713,8 +1691,6 @@ togglefloating(const Arg *arg) | |
125 { | |
126 if (!selmon->sel) | |
127 return; | |
128 - if (selmon->sel->isfullscreen) /* no support for fullscreen win… | |
129 - return; | |
130 selmon->sel->isfloating = !selmon->sel->isfloating || selmon->s… | |
131 if (selmon->sel->isfloating) | |
132 resize(selmon->sel, selmon->sel->x, selmon->sel->y, | |
133 -- | |
134 2.31.1 | |
135 |