gtk: Add suspended window state
authorJonas Ådahl <jadahl@gmail.com>
Wed, 24 May 2023 14:22:42 +0000 (16:22 +0200)
committerMatthias Clasen <mclasen@redhat.com>
Sun, 30 Jul 2023 08:40:09 +0000 (11:40 +0300)
commit7f946eff0163e84e34a1880f068f7f5efb354add
treeaf8a269aa7e6c86336f3a4670545dd6a1c42e774
parent03a8b9cf1768b4abd119c63f1c01cf3c5d13eeae
gtk: Add suspended window state

This is implemented using a new xdg_toplevel `suspended` state, and is
meant for allowing applications to know when they can stop doing
unnecessary work and thus save power.

In the other backends, the `suspended` state is set at the same time as
`minimized` as it's the closest there is to traditional windowing
systems.
12 files changed:
gdk/gdktoplevel.h
gdk/macos/GdkMacosWindow.c
gdk/wayland/gdktoplevel-wayland.c
gdk/win32/gdkevents-win32.c
gdk/x11/gdkdisplay-x11.c
gdk/x11/gdksurface-x11.c
gtk/gtkwindow.c
gtk/gtkwindow.h
meson.build
tests/meson.build
tests/testgtk.c
tests/testsuspended.c [new file with mode: 0644]