mirror of
https://github.com/swaywm/sway.git
synced 2024-12-29 00:16:22 +01:00
swaybar: when scrolling, check that there are workspaces to scroll on
This commit is contained in:
parent
c5541763c0
commit
19421373b9
1 changed files with 4 additions and 0 deletions
|
@ -180,6 +180,10 @@ static void wl_pointer_axis(void *data, struct wl_pointer *wl_pointer,
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!sway_assert(!wl_list_empty(&output->workspaces), "axis with no workspaces")) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
struct swaybar_workspace *first =
|
struct swaybar_workspace *first =
|
||||||
wl_container_of(output->workspaces.next, first, link);
|
wl_container_of(output->workspaces.next, first, link);
|
||||||
struct swaybar_workspace *last =
|
struct swaybar_workspace *last =
|
||||||
|
|
Loading…
Reference in a new issue