about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--client.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/client.c b/client.c
index 5309d0e..5c69718 100644
--- a/client.c
+++ b/client.c
@@ -79,15 +79,16 @@ configure(Client *c) {
 
 void
 focus(Client *c) {
-	Client *old = sel;
-
 	if(c && !isvisible(c))
 		return;
 
-	if(old && old != c) {
-		grabbuttons(old, False);
-		XSetWindowBorder(dpy, old->win, dc.norm[ColBorder]);
+	if(sel && sel != c) {
+		grabbuttons(sel, False);
+		XSetWindowBorder(dpy, sel->win, dc.norm[ColBorder]);
 	}
+	sel = c;
+	if(!issel)
+		return;
 	if(c) {
 		detachstack(c);
 		c->snext = stack;
@@ -96,9 +97,8 @@ focus(Client *c) {
 		XSetWindowBorder(dpy, c->win, dc.sel[ColBorder]);
 		XSetInputFocus(dpy, c->win, RevertToPointerRoot, CurrentTime);
 	}
-	else if(issel)
+	else
 		XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime);
-	sel = c;
 	drawstatus();
 }
 
'/ingrix/lynx-snapshots/commit/lynx_help/keystrokes/xterm_help.html?id=7c7d8c9582cea3ed0ff52f6e7d212fa85b3cd75f'>7c7d8c95 ^
35787b45 ^
bc0fa578 ^
5ae317fd ^








bc0fa578 ^
















5ae317fd ^

bc0fa578 ^
5ae317fd ^
bc0fa578 ^







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52