]> git.mdlowis.com Git - proto/labwc.git/commitdiff
src/workspaces.c: update cursor focus
authorConsolatis <35009135+Consolatis@users.noreply.github.com>
Sun, 5 Mar 2023 15:34:41 +0000 (16:34 +0100)
committerJohan Malm <johanmalm@users.noreply.github.com>
Sun, 5 Mar 2023 21:07:58 +0000 (21:07 +0000)
Fixes #807

src/workspaces.c

index e3c149de8878c92e621606ecd45511d72f1cfe75..625a8d8bce2a459d8d731519825299a8f5d304f2 100644 (file)
@@ -271,6 +271,12 @@ workspaces_switch_to(struct workspace *target)
 
        /* And finally show the OSD */
        _osd_show(server);
+
+       /*
+        * Make sure we are not carrying around a
+        * cursor image from the previous desktop
+        */
+       cursor_update_focus(server);
 }
 
 void
@@ -284,6 +290,9 @@ workspaces_osd_hide(struct seat *seat)
                wlr_scene_buffer_set_buffer(output->workspace_osd, NULL);
        }
        seat->workspace_osd_shown_by_modifier = false;
+
+       /* Update the cursor focus in case it was on top of the OSD before */
+       cursor_update_focus(server);
 }
 
 struct workspace *