Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(609)

Issue 1296533003: Introduce WebPageImportanceSignals to judge state preservation needs (Closed)

Created:
5 years, 4 months ago by kouhei (in TOK)
Modified:
5 years, 4 months ago
CC:
blink-reviews, dglazkov+blink, blink-reviews-html_chromium.org
Target Ref:
refs/remotes/origin/master
Project:
blink
Visibility:
Public.

Description

Introduce WebPageImportanceSignals to judge state preservation needs This CL introduces WebPageImportanceSignals, which is measured per Page. We plan to propagate this signal to content/ so that Chromium can judge the importance of the tab. Chromium can then use this signal to choose which actions to take against the tab when we are approaching system resource limit. For example: - Simply discard the tab if user hadn't done anything with the tab. - If he/she entered something on a form, we better preserve its state, etc. To start with, we record if user has interacted with a HTML form on the page. BUG=520838 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=200630

Patch Set 1 #

Patch Set 2 : document().frame() may be null during the tests #

Total comments: 8

Patch Set 3 : add comment/disallow_allocation #

Patch Set 4 : add missing includes #

Total comments: 2

Patch Set 5 : migrate to web/ per suggestion from tkent #

Patch Set 6 : add missing header #

Total comments: 4

Patch Set 7 : nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+69 lines, -2 lines) Patch
M Source/core/page/ChromeClient.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M Source/web/ChromeClientImpl.cpp View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
A Source/web/WebPageImportanceSignals.cpp View 1 2 3 4 1 chunk +24 lines, -0 lines 0 comments Download
M Source/web/WebViewImpl.h View 1 2 3 4 3 chunks +5 lines, -0 lines 0 comments Download
M Source/web/WebViewImpl.cpp View 1 2 3 4 1 chunk +3 lines, -1 line 0 comments Download
M Source/web/web.gypi View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A public/web/WebPageImportanceSignals.h View 1 2 3 4 5 6 1 chunk +33 lines, -0 lines 0 comments Download

Messages

Total messages: 41 (18 generated)
kouhei (in TOK)
PTAL
5 years, 4 months ago (2015-08-14 05:43:48 UTC) #2
kouhei (in TOK)
+georgesak: FYI. We want to plumb this to tab_stats in future.
5 years, 4 months ago (2015-08-14 05:45:49 UTC) #4
tzik
lgtm
5 years, 4 months ago (2015-08-14 07:42:57 UTC) #5
keishi
LGTM
5 years, 4 months ago (2015-08-14 07:45:45 UTC) #6
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/20001
5 years, 4 months ago (2015-08-14 07:46:18 UTC) #10
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_x64_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/90578)
5 years, 4 months ago (2015-08-14 09:18:39 UTC) #12
haraken
LGTM https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.cpp File Source/core/frame/PageImportanceSignals.cpp (right): https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.cpp#newcode19 Source/core/frame/PageImportanceSignals.cpp:19: m_hadFormInteraction = false; m_didObserveFormInteraction? https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.cpp#newcode22 Source/core/frame/PageImportanceSignals.cpp:22: void PageImportanceSignals::setHadFormInteraction() ...
5 years, 4 months ago (2015-08-14 14:42:50 UTC) #13
kouhei (in TOK)
https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.cpp File Source/core/frame/PageImportanceSignals.cpp (right): https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.cpp#newcode19 Source/core/frame/PageImportanceSignals.cpp:19: m_hadFormInteraction = false; On 2015/08/14 14:42:50, haraken wrote: > ...
5 years, 4 months ago (2015-08-17 03:31:31 UTC) #14
kouhei (in TOK)
https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.h File Source/core/frame/PageImportanceSignals.h (right): https://codereview.chromium.org/1296533003/diff/20001/Source/core/frame/PageImportanceSignals.h#newcode10 Source/core/frame/PageImportanceSignals.h:10: class PageImportanceSignals { On 2015/08/14 14:42:50, haraken wrote: > ...
5 years, 4 months ago (2015-08-17 03:44:36 UTC) #15
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/40001
5 years, 4 months ago (2015-08-17 03:44:46 UTC) #17
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_linux on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell_linux/builds/42576) linux_chromium_rel_ng on ...
5 years, 4 months ago (2015-08-17 03:53:50 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/50009 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/50009
5 years, 4 months ago (2015-08-17 04:11:08 UTC) #22
tkent
I think this should not be in 'core'. Don't we have enough hooks with which ...
5 years, 4 months ago (2015-08-17 04:15:20 UTC) #23
tkent
https://codereview.chromium.org/1296533003/diff/50009/Source/core/html/HTMLFormControlElement.cpp File Source/core/html/HTMLFormControlElement.cpp (right): https://codereview.chromium.org/1296533003/diff/50009/Source/core/html/HTMLFormControlElement.cpp#newcode322 Source/core/html/HTMLFormControlElement.cpp:322: void HTMLFormControlElement::dispatchChangeEvent() Input events are more appropriate than change ...
5 years, 4 months ago (2015-08-17 04:17:56 UTC) #26
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/70001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/70001
5 years, 4 months ago (2015-08-17 05:14:36 UTC) #28
kouhei (in TOK)
tkent-san. PTAL https://codereview.chromium.org/1296533003/diff/50009/Source/core/html/HTMLFormControlElement.cpp File Source/core/html/HTMLFormControlElement.cpp (right): https://codereview.chromium.org/1296533003/diff/50009/Source/core/html/HTMLFormControlElement.cpp#newcode322 Source/core/html/HTMLFormControlElement.cpp:322: void HTMLFormControlElement::dispatchChangeEvent() On 2015/08/17 04:17:56, tkent wrote: ...
5 years, 4 months ago (2015-08-17 05:17:10 UTC) #29
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/90001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/90001
5 years, 4 months ago (2015-08-17 05:19:27 UTC) #31
tkent
lgtm https://codereview.chromium.org/1296533003/diff/90001/public/web/WebPageImportanceSignals.h File public/web/WebPageImportanceSignals.h (right): https://codereview.chromium.org/1296533003/diff/90001/public/web/WebPageImportanceSignals.h#newcode8 public/web/WebPageImportanceSignals.h:8: #include "../platform/WebCommon.h" Please do not use relative include ...
5 years, 4 months ago (2015-08-17 05:26:29 UTC) #32
kouhei (in TOK)
Thanks! https://codereview.chromium.org/1296533003/diff/90001/public/web/WebPageImportanceSignals.h File public/web/WebPageImportanceSignals.h (right): https://codereview.chromium.org/1296533003/diff/90001/public/web/WebPageImportanceSignals.h#newcode8 public/web/WebPageImportanceSignals.h:8: #include "../platform/WebCommon.h" On 2015/08/17 05:26:29, tkent wrote: > ...
5 years, 4 months ago (2015-08-17 05:28:45 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/110001
5 years, 4 months ago (2015-08-17 05:28:46 UTC) #36
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_asan_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_asan_rel_ng/builds/40242)
5 years, 4 months ago (2015-08-17 06:39:08 UTC) #38
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1296533003/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1296533003/110001
5 years, 4 months ago (2015-08-17 06:39:34 UTC) #40
commit-bot: I haz the power
5 years, 4 months ago (2015-08-17 07:17:10 UTC) #41
Message was sent while issue was closed.
Committed patchset #7 (id:110001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=200630

Powered by Google App Engine
This is Rietveld 408576698