mirror of
https://github.com/swaywm/sway.git
synced 2024-11-23 00:11:28 +00:00
cmd_focus: show scratchpad if hidden
If a scratchpad container is hidden, it is still focusable using criteria and should be shown. This fixes a segfault when attempting to rebase the cursor since previously the scratchpad container would not be on any output.
This commit is contained in:
parent
6788910fd7
commit
2942bbbc60
|
@ -269,6 +269,9 @@ struct cmd_results *cmd_focus(int argc, char **argv) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (argc == 0 && container) {
|
if (argc == 0 && container) {
|
||||||
|
if (container->scratchpad && !container->workspace) {
|
||||||
|
root_scratchpad_show(container);
|
||||||
|
}
|
||||||
seat_set_focus_container(seat, container);
|
seat_set_focus_container(seat, container);
|
||||||
seat_consider_warp_to_focus(seat);
|
seat_consider_warp_to_focus(seat);
|
||||||
return cmd_results_new(CMD_SUCCESS, NULL, NULL);
|
return cmd_results_new(CMD_SUCCESS, NULL, NULL);
|
||||||
|
|
Loading…
Reference in a new issue