It seems gnome-session got fixed for this now. When I press the power button, I now get the usual dialog that asks you what to do (shutdown/reboot/etc.)
I'll add a task for kde-workspace as apparently it's still not working under KDE. I. e. the KDE session needs to inhibit logind's power button handling if it wants to handle the power button itself, similar to what gnome-session is doing in gsm_systemd_add_inhibitor() (https://git.gnome.org/browse/gnome-session/tree/gnome-session/gsm-systemd.c#n750)
It seems gnome-session got fixed for this now. When I press the power button, I now get the usual dialog that asks you what to do (shutdown/ reboot/ etc.)
I'll add a task for kde-workspace as apparently it's still not working under KDE. I. e. the KDE session needs to inhibit logind's power button handling if it wants to handle the power button itself, similar to what gnome-session is doing in gsm_systemd_ add_inhibitor( ) (https:/ /git.gnome. org/browse/ gnome-session/ tree/gnome- session/ gsm-systemd. c#n750)