mirror of
https://codeberg.org/dnkl/yambar.git
synced 2025-04-20 03:35:41 +02:00
bar/wayland: Reset last_mapped_monitor on enter
If the surface enters an output, there's no need for last_mapped_monitor, and it must be reset to fulfill the asserts in other parts of the code. This makes yambar no longer crash when it is hidden by an opaque window multiple times on a compositor using wlroots' scene tree.
This commit is contained in:
parent
60671da2ca
commit
1283160e17
1 changed files with 3 additions and 0 deletions
|
@ -1339,6 +1339,9 @@ surface_enter(void *data, struct wl_surface *wl_surface,
|
||||||
{
|
{
|
||||||
struct wayland_backend *backend = data;
|
struct wayland_backend *backend = data;
|
||||||
|
|
||||||
|
free(backend->last_mapped_monitor);
|
||||||
|
backend->last_mapped_monitor = NULL;
|
||||||
|
|
||||||
tll_foreach(backend->monitors, it) {
|
tll_foreach(backend->monitors, it) {
|
||||||
struct monitor *mon = &it->item;
|
struct monitor *mon = &it->item;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue