on xenial help sign in
Show greeter when powerd tells us too, not just everytime we press the power key
commit8359d298a522038671b0038bfe18702937bf0742 authorMichael Terry <michael.terry@canonical.com> dateFri 2 Aug 2013, 15:10 (13 years ago) parentb754d9f
1 file changed+1−6
Shell.qml+1−6
Shell.qml+1−6
@@ -128,12 +128,6 @@ FocusScope {
128128 Keys.onVolumeUpPressed: volumeControl.volumeUp()
129129 Keys.onVolumeDownPressed: volumeControl.volumeDown()
130130
131− Keys.onReleased: {
132− if (event.key == Qt.Key_PowerOff) {
133− greeter.show()
134− }
135− }
136−
137131 Item {
138132 id: underlay
139133 objectName: "underlay"
@@ -488,6 +482,7 @@ FocusScope {
488482 onPowerStateChange: {
489483 if (state == 0) { // suspend
490484 powerConnection.setFocused(false);
485+ greeter.show();
491486 } else if (state == 1) { // active
492487 powerConnection.setFocused(true);
493488 }