summaryrefslogtreecommitdiffstats
path: root/desktop/sfwbar/inhibit_check.patch
diff options
context:
space:
mode:
Diffstat (limited to 'desktop/sfwbar/inhibit_check.patch')
-rw-r--r--desktop/sfwbar/inhibit_check.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/desktop/sfwbar/inhibit_check.patch b/desktop/sfwbar/inhibit_check.patch
new file mode 100644
index 0000000000..1c61883cf2
--- /dev/null
+++ b/desktop/sfwbar/inhibit_check.patch
@@ -0,0 +1,22 @@
+--- a/src/wayland.c 2022-04-14 21:01:09.000000000 +0100
++++ b/src/wayland.c 2022-05-16 21:32:21.208252447 +0100
+@@ -215,6 +215,9 @@
+ struct wl_surface *surface;
+ struct zwp_idle_inhibitor_v1 *inhibitor;
+
++ if(!idle_inhibit_manager)
++ return;
++
+ surface = gdk_wayland_window_get_wl_surface(
+ gtk_widget_get_window(widget));
+ inhibitor = g_object_get_data(G_OBJECT(widget),"inhibitor");
+@@ -237,6 +240,9 @@
+
+ void wayland_reset_inhibitors ( GtkWidget *w, gpointer data )
+ {
++ if(!idle_inhibit_manager)
++ return;
++
+ if(GTK_IS_CONTAINER(w))
+ gtk_container_foreach(GTK_CONTAINER(w),wayland_reset_inhibitors,data);
+