WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
194500
[WPE][GTK] Sleep disabler code should inhibit idle when a "System" sleep disabler is requested
https://bugs.webkit.org/show_bug.cgi?id=194500
Summary
[WPE][GTK] Sleep disabler code should inhibit idle when a "System" sleep disa...
Michael Catanzaro
Reported
2019-02-11 08:07:42 PST
Splitting this out of
bug #18697
, I see I wrote this comment when writing SleepDisablerGlib: // We don't support suspend ("System") inhibitors, only idle inhibitors. // To get suspend inhibitors, we'd need to use the fancy GNOME // SessionManager API, which requires registering as a client application, // which is not practical from the web process. Secondly, because the only // current use of a suspend inhibitor in WebKit, // HTMLMediaElement::shouldDisableSleep, is suspicious. There's really no // valid reason for WebKit to ever block suspend, only idle. There are three things wrong with this comment: * Nowadays, GNOME suspends the computer automatically on inactivity, and we actually do want to prevent that. * Inhibiting idle does affect the autosuspend countdown. So the current code should prevent automatic suspend, just not manual suspend. (I think I stand by my comment that we do not want to inhibit normal suspend, since that would just be annoying.) * I don't know why I thought HTMLMediaElement::shouldDisableSleep was suspicious. Anyway, I guess the behavior we want is to ignore the Type argument and just always inhibit idle. That is, treat type=System the same way we current treat type=Display. I couldn't decide which to do when I wrote this code, but in retrospect that would have been a better option.
Attachments
Patch
(3.31 KB, patch)
2019-02-11 08:22 PST
,
Michael Catanzaro
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Michael Catanzaro
Comment 1
2019-02-11 08:19:22 PST
(In reply to Michael Catanzaro from
comment #0
)
> Splitting this out of
bug #18697
I meant
bug #186971
Michael Catanzaro
Comment 2
2019-02-11 08:22:17 PST
Created
attachment 361680
[details]
Patch
WebKit Commit Bot
Comment 3
2019-02-12 01:29:52 PST
Comment on
attachment 361680
[details]
Patch Clearing flags on attachment: 361680 Committed
r241290
: <
https://trac.webkit.org/changeset/241290
>
WebKit Commit Bot
Comment 4
2019-02-12 01:29:54 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug