mirror of
https://github.com/labwc/labwc.git
synced 2026-04-07 08:21:20 -04:00
cycle: remember cycled window list in server->cycle.views
This allows changing the cycled order in the future, e.g. focused order vs created order. Functionally, this commit also changes the initially selected window; before this commit, the previous/next of the topmost window was always selected, but now the previous/next of the active window is selected first if it is in the cycled list. This won't change behaviors for most users, but this ensures that the user can go back to the focused window with Alt-Tab + Alt-Shift-Tab even when it is not the topmost window. This commit fixes the TODO in the previous commit by trying to preserve the selected view when a view is destroyed during window cycling.
This commit is contained in:
parent
09fbf94b69
commit
bd0923dc76
8 changed files with 92 additions and 110 deletions
|
|
@ -303,6 +303,7 @@ struct server {
|
|||
/* Set when in cycle (alt-tab) mode */
|
||||
struct cycle_state {
|
||||
struct view *selected_view;
|
||||
struct wl_list views;
|
||||
bool preview_was_shaded;
|
||||
bool preview_was_enabled;
|
||||
struct wlr_scene_node *preview_node;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue