about summary refs log tree commit diff stats
path: root/dwm.c
diff options
context:
space:
mode:
authorAnselm R Garbe <anselm@garbe.us>2009-06-27 17:38:18 +0100
committerAnselm R Garbe <anselm@garbe.us>2009-06-27 17:38:18 +0100
commit64674c395b89f8d9640163cdcf9c8f4e25ba0e9c (patch)
treebe8d789b339bfc171a77298709f6f7e66595f4af /dwm.c
parentb9dee2c6f172478b7a652cdf9d074ee0bd9acddc (diff)
downloaddwm-64674c395b89f8d9640163cdcf9c8f4e25ba0e9c.tar.gz
fixed focusmon brokeness
Diffstat (limited to 'dwm.c')
-rw-r--r--dwm.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/dwm.c b/dwm.c
index 2588153..096895c 100644
--- a/dwm.c
+++ b/dwm.c
@@ -804,13 +804,11 @@ focusmon(const Arg *arg) {
 
 	for(i = 0, m = mons; m; m = m->next, i++)
 		if(i == arg->ui) {
-			if(m->stack)
-				focus(m->stack);
-			else {
-				unfocus(selmon->stack);
-				selmon = m;
-				focus(NULL);
-			}
+			if(m == selmon)
+				return;
+			unfocus(selmon->sel);
+			selmon = m;
+			focus(NULL);
 			drawbars();
 			break;
 		}
12c08'>112613fe ^
c91caafd ^







d082b176 ^







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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91