Skip to content

Remove special hardcoded handling for tablets

Quite some time ago special hard-coded handling for tablets was added to gsd-power-manager to automatically suspend the tablet when the screen is blanked or the power-button is pressed.

With the more recent auto-suspend (when on battery power) support, the hardcoded suspend on blank behavior really is no longer necessary, if the auto-suspend timeout gets set to the same value as the blank timeout the same result is achieved, but now under user control, rather then being hardcoded.

Not having this hardcoded is desirable because suspend is not always desirable, e.g. when ongoing downloads are active, or other network connections are open such as an irc client.

The harcoded behavior is especially troublesome because it not only triggers on actual tablets, but also on various non tablet devices, both surface like devices, which are aften used as one would use a laptop, as well as on some actual laptops. On laptops one may typically have an irc-client open, network downloads ongoing, etc. and then lock the screen when walking away. The current hardcoded suspend behavior causes the downloads to abort, irc messages to be missed, etc. and with this not being configurable there is nothing the user can do to avoid this.

I've looked into making gsd_power_is_hardware_a_tablet() more reliable, but this relies on the DMI chassis type, which ultimately simply is unreliable. Since we have configurable options for both hardcoded behaviors now this patch series fixes the issues with the hardcoded behavior by removing it.

Merge request reports