mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 16:06:37 +01:00
idle_inhibit: Fix tree view after changes in commit 152a559e
Commit 152a559e
replaced the view pointer in the inhibitor struct with a
pointer to the wlr_inhibitor for application inhibitors. But this was not
changed in the sway_idle_inhibit_v1_application_inhibitor_for_view function.
This caused a bug in the sway tree view where the application inhibitor is
always "none".
This commit is contained in:
parent
8aae6a8eab
commit
8fa7b99859
1 changed files with 4 additions and 4 deletions
|
@ -69,8 +69,8 @@ struct sway_idle_inhibitor_v1 *sway_idle_inhibit_v1_user_inhibitor_for_view(
|
||||||
struct sway_idle_inhibitor_v1 *inhibitor;
|
struct sway_idle_inhibitor_v1 *inhibitor;
|
||||||
wl_list_for_each(inhibitor, &server.idle_inhibit_manager_v1->inhibitors,
|
wl_list_for_each(inhibitor, &server.idle_inhibit_manager_v1->inhibitors,
|
||||||
link) {
|
link) {
|
||||||
if (inhibitor->view == view &&
|
if (inhibitor->mode != INHIBIT_IDLE_APPLICATION &&
|
||||||
inhibitor->mode != INHIBIT_IDLE_APPLICATION) {
|
inhibitor->view == view) {
|
||||||
return inhibitor;
|
return inhibitor;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -82,8 +82,8 @@ struct sway_idle_inhibitor_v1 *sway_idle_inhibit_v1_application_inhibitor_for_vi
|
||||||
struct sway_idle_inhibitor_v1 *inhibitor;
|
struct sway_idle_inhibitor_v1 *inhibitor;
|
||||||
wl_list_for_each(inhibitor, &server.idle_inhibit_manager_v1->inhibitors,
|
wl_list_for_each(inhibitor, &server.idle_inhibit_manager_v1->inhibitors,
|
||||||
link) {
|
link) {
|
||||||
if (inhibitor->view == view &&
|
if (inhibitor->mode == INHIBIT_IDLE_APPLICATION &&
|
||||||
inhibitor->mode == INHIBIT_IDLE_APPLICATION) {
|
view_from_wlr_surface(inhibitor->wlr_inhibitor->surface) == view) {
|
||||||
return inhibitor;
|
return inhibitor;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue