Merge lp:~mterry/unity8/no-shutdown-dialog-while-suspended into lp:unity8

Proposed by Michael Terry
Status: Merged
Approved by: Gerry Boland
Approved revision: 1547
Merged at revision: 1562
Proposed branch: lp:~mterry/unity8/no-shutdown-dialog-while-suspended
Merge into: lp:unity8
Diff against target: 21 lines (+10/-1)
1 file modified
qml/Shell.qml (+10/-1)
To merge this branch: bzr merge lp:~mterry/unity8/no-shutdown-dialog-while-suspended
Reviewer Review Type Date Requested Status
Gerry Boland (community) Approve
PS Jenkins bot (community) continuous-integration Needs Fixing
Review via email: mp+246445@code.launchpad.net

Commit message

Don't show any power dialogs while the screen is off. This is a band-aid to avoid the symptom, while we still investigate the source of why the screen doesn't turn on (and why we seem to not handle the power-button-release event).

Description of the change

Don't show any power dialogs while the screen is off.

From the code:

// FIXME: We only consider power key presses if the screen is
// on because of bug 1410830. The theory is that when that bug
// is encountered, there is a >2s delay between the power press
// event and the power release event, which causes the shutdown
// dialog to appear on resume. So to avoid that symptom while
// we investigate the root cause, we simply won't initiate any
// dialogs when the screen is off.

So to be clear, this is a band-aid to avoid the symptom, while we still investigate the source of why the screen doesn't turn on (and why we seem to not handle the power-button-release event).

To make it worse, this bug is hard to reproduce. I'm not even really sure this band-aid fixes the symptom. But it seems like it would. So that's basically the same, right!?

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
kevin gunn (kgunn72) wrote :

this was tested by rick against jibel's repro method many times - this fix corrected that
since rick has the magic handset & user mojo he is currently testing his roaming-test, so far so good, testing overnight as well.

Revision history for this message
Michael Terry (mterry) wrote :

<kgunn> mterry: so rick said he never saw the poweroff dialog, but did experience the busy/slow resume

So that seems promising.

1547. By Michael Terry

Reference Rick's bug too

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Gerry Boland (gerboland) wrote :

I can't reproduce this, but as other people can, the fix is logical

review: Approve
1548. By Michael Terry

Merge from trunk

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'qml/Shell.qml'
2--- qml/Shell.qml 2015-01-09 10:41:41 +0000
3+++ qml/Shell.qml 2015-01-21 14:43:33 +0000
4@@ -181,7 +181,16 @@
5 WindowKeysFilter {
6 Keys.onPressed: {
7 if (event.key == Qt.Key_PowerOff || event.key == Qt.Key_PowerDown) {
8- dialogs.onPowerKeyPressed();
9+ // FIXME: We only consider power key presses if the screen is
10+ // on because of bugs 1410830/1409003. The theory is that when
11+ // those bugs are encountered, there is a >2s delay between the
12+ // power press event and the power release event, which causes
13+ // the shutdown dialog to appear on resume. So to avoid that
14+ // symptom while we investigate the root cause, we simply won't
15+ // initiate any dialogs when the screen is off.
16+ if (Powerd.status === Powerd.On) {
17+ dialogs.onPowerKeyPressed();
18+ }
19 event.accepted = true;
20 } else {
21 volumeKeyFilter.onKeyPressed(event.key);

Subscribers

People subscribed via source and target branches