git.lucas.co / cce-compositor
Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git

commit47541cf3ff4ae8d295f5c0930a4794f1705f3bf1
parent0953d69574
authorIsaac Freund <[email protected]>
date2020-04-04 19:48
Reset focus on switching between tags

 src/root.zig | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/root.zig b/src/root.zig
index af1cff8..9700827 100644
--- a/src/root.zig
+++ b/src/root.zig
@@ -318,6 +318,9 @@ pub const Root = struct {
             );
             self.current_focused_tags = tags;
             self.pending_focused_tags = null;
+
+            self.focused_view = null;
+            self.focusNextView();
         }
 
         var it = ViewStack.iterator(self.views.first, 0xFFFFFFFF);