Bug 169417 - [WK2] Prevent app nap for the active tab
Summary: [WK2] Prevent app nap for the active tab
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-03-09 09:36 PST by Chris Dumez
Modified: 2017-03-09 10:54 PST (History)
5 users (show)

See Also:


Attachments
Patch (2.51 KB, patch)
2017-03-09 09:39 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2017-03-09 09:36:24 PST
Prevent app nap for the active tab to minimize the risks of breakage.

From the AppNap documentation [1], the app is only a candidate for app nap if it not the foreground app. However, in the Safari case, the foreground app is Safari (UIProcess) and the same policy does not apply to our foreground WebContent process unless we explicitly make it so.

[1] https://developer.apple.com/library/content/documentation/Performance/Conceptual/power_efficiency_guidelines_osx/AppNap.html
Comment 1 Chris Dumez 2017-03-09 09:36:44 PST
<rdar://problem/30876965>
Comment 2 Chris Dumez 2017-03-09 09:39:00 PST
Created attachment 303926 [details]
Patch
Comment 3 Chris Dumez 2017-03-09 10:02:20 PST
<rdar://problem/30318924>
Comment 4 WebKit Commit Bot 2017-03-09 10:54:05 PST
Comment on attachment 303926 [details]
Patch

Clearing flags on attachment: 303926

Committed r213649: <http://trac.webkit.org/changeset/213649>
Comment 5 WebKit Commit Bot 2017-03-09 10:54:11 PST
All reviewed patches have been landed.  Closing bug.