Disable volume adjustments while the screen is off
What problem did you encounter
Volume can be adjusted for locked user sessions with a blank screen on the Pinephone with the latest version of Mobian.
What is the current behaviour?
Volume can be adjusted while the user session is locked and the screen is off. Pressing either volume button will play a system sound to confirm the change, and will then turn the screen on. The current behavior makes it very easy to not only inadvertently raise or lower the Pinephone's volume while carrying it in a pocket, bag, etc, but to also drain the Pinephone's battery via accidental volume button presses.
What is the expected behaviour?
Volume should not be adjustable unless the screen is on. Also, the screen shouldn't turn on by pressing either volume button.
How to reproduce
- Lock the current user session on the Pinephone or allow the session to time out.
- Ensure that the screen is blank and press either volume key.
- System sounds (if enabled) confirm that volume is changed, and the screen will power on.
Which version did you encounter the bug in?
$ dpkg -s phosh
Package: phosh
Status: install ok installed
Priority: optional
Section: x11
Installed-Size: 1416
Maintainer: DebianOnMobile Maintainers <debian-on-mobile-maintainers@alioth-lists.debian.net>
Architecture: arm64
Version: 0.8.1-1mobian1
Provides: notification-daemon, polkit-1-auth-agent
Depends: dconf-gsettings-backend | gsettings-backend, libc6 (>= 2.17), libcairo2 (>= 1.2.4), libfeedback-0.0-0 (>= 0.0.0+git20200305), libgcr-base-3-1 (>= 3.8.0), libgcr-ui-3-1 (>= 3.8.0), libgdk-pixbuf-2.0-0 (>= 2.23.0), libglib2.0-0 (>= 2.59.2), libgnome-desktop-3-19 (>= 3.17.92), libgtk-3-0 (>= 3.21.5), libhandy-1-0 (>= 1.0.2), libnm0 (>= 1.0.0), libpam0g (>= 0.99.7.1), libpango-1.0-0 (>= 1.37.2), libpolkit-agent-1-0 (>= 0.99), libpolkit-gobject-1-0 (>= 0.94), libpulse-mainloop-glib0 (>= 0.99.1), libpulse0 (>= 0.99.1), libsecret-1-0 (>= 0.7), libsystemd0 (>= 217), libupower-glib3 (>= 0.99.4-3~), libwayland-client0 (>= 1.9.91), fonts-lato, gnome-shell-common, gsettings-desktop-schemas, phoc (>= 0.4.4)
Recommends: feedbackd, gnome-session-bin, gnome-session-common, gnome-settings-daemon, iio-sensor-proxy, phosh-mobile-tweaks, squeekboard | phosh-osk-stub
Description: Pure Wayland shell for mobile devices
Phosh is a graphical shell for Wayland compositors speaking the layer-surface
protocol and aimed at mobile devices like smart phones and tablets using touch
based inputs and small screens.
.
It's part of the Phosh Mobile Environment based on GNOME/GTK. For the full
stack see the phosh-full and phosh-core metapackages.
Homepage: https://source.puri.sm/Librem5/phosh
What hardware are you running phosh on?
- Pinephone CE
Releveant logfiles
Not sure which logs would be helpful for this, but I'll gladly provide any that you need.