Don't unconditionally emit buttonPressed on profile load

Authored by broulik on Aug 10 2016, 7:32 AM.

Description

Don't unconditionally emit buttonPressed on profile load

A button press (technically the "lid closed" event is also a button press) should
always be some consicious action triggered by the user. By emitting this signal
unconditionally on profile load (ie. whenever changing an activity or (un)plugging AC)
the session might always lock or suspend when this happens.

If and only if a profile would really like to take some action or set some state
depending on the lid state on profile load - which none do, the handle button
press action should only react on explicit button presses anyway - it can still
ask the backend for isLidClosed in its onProfileLoad method.

BUG: 366125
FIXED-IN: 5.7.4

Differential Revision: https://phabricator.kde.org/D2325