OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "config.h" | 5 #include "config.h" |
6 #include "public/web/WebPageImportanceSignals.h" | 6 #include "public/web/WebPageImportanceSignals.h" |
7 #include "public/web/WebViewClient.h" | |
8 | 7 |
9 #include "public/platform/Platform.h" | 8 #include "public/platform/Platform.h" |
9 #include "public/web/WebViewClient.h" | |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 void WebPageImportanceSignals::reset() | 13 void WebPageImportanceSignals::reset() |
14 { | 14 { |
15 m_hadFormInteraction = false; | 15 m_hadFormInteraction = false; |
tyoshino (SeeGerritForStatus)
2015/09/25 06:22:45
reset m_issuedNonGetFetchFromScrip
kouhei (in TOK)
2015/09/25 08:47:35
Done.
| |
16 if (m_observer) | 16 if (m_observer) |
17 m_observer->pageImportanceSignalsChanged(); | 17 m_observer->pageImportanceSignalsChanged(); |
18 } | 18 } |
19 | 19 |
20 void WebPageImportanceSignals::setHadFormInteraction() | 20 void WebPageImportanceSignals::setHadFormInteraction() |
21 { | 21 { |
22 m_hadFormInteraction = true; | 22 m_hadFormInteraction = true; |
23 if (m_observer) | 23 if (m_observer) |
24 m_observer->pageImportanceSignalsChanged(); | 24 m_observer->pageImportanceSignalsChanged(); |
25 } | 25 } |
26 | 26 |
27 void WebPageImportanceSignals::setIssuedNonGetFetchFromScript() | |
28 { | |
29 m_issuedNonGetFetchFromScript = false; | |
tyoshino (SeeGerritForStatus)
2015/09/25 06:22:44
hmm, true?
kouhei (in TOK)
2015/09/25 08:47:35
Done.
| |
30 if (m_observer) | |
31 m_observer->pageImportanceSignalsChanged(); | |
32 } | |
33 | |
27 void WebPageImportanceSignals::onCommitLoad() | 34 void WebPageImportanceSignals::onCommitLoad() |
28 { | 35 { |
29 Platform::current()->histogramEnumeration("PageImportanceSignals.HadFormInte raction.OnCommitLoad", m_hadFormInteraction, 2); | 36 Platform::current()->histogramEnumeration("PageImportanceSignals.HadFormInte raction.OnCommitLoad", m_hadFormInteraction, 2); |
37 Platform::current()->histogramEnumeration("PageImportanceSignals.IssuedNonGe tFetchFromScript.OnCommitLoad", m_issuedNonGetFetchFromScript, 2); | |
30 | 38 |
31 reset(); | 39 reset(); |
32 } | 40 } |
33 | 41 |
34 } // namespace blink | 42 } // namespace blink |
OLD | NEW |