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

Side by Side Diff: third_party/WebKit/Source/core/frame/OriginsUsingFeatures.cpp

Issue 1773813007: blink: Rename modules/ method to prefix with get when they collide. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: clash-modules: rebase-fixes Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "core/frame/OriginsUsingFeatures.h" 5 #include "core/frame/OriginsUsingFeatures.h"
6 6
7 #include "bindings/core/v8/ScriptState.h" 7 #include "bindings/core/v8/ScriptState.h"
8 #include "core/dom/Document.h" 8 #include "core/dom/Document.h"
9 #include "core/page/Page.h" 9 #include "core/page/Page.h"
10 #include "public/platform/Platform.h" 10 #include "public/platform/Platform.h"
(...skipping 17 matching lines...) Expand all
28 28
29 void OriginsUsingFeatures::countMainWorldOnly(const ScriptState* scriptState, Do cument& document, Feature feature) 29 void OriginsUsingFeatures::countMainWorldOnly(const ScriptState* scriptState, Do cument& document, Feature feature)
30 { 30 {
31 if (!scriptState || !scriptState->world().isMainWorld()) 31 if (!scriptState || !scriptState->world().isMainWorld())
32 return; 32 return;
33 countAnyWorld(document, feature); 33 countAnyWorld(document, feature);
34 } 34 }
35 35
36 static Document* documentFromEventTarget(EventTarget& target) 36 static Document* documentFromEventTarget(EventTarget& target)
37 { 37 {
38 ExecutionContext* executionContext = target.executionContext(); 38 ExecutionContext* executionContext = target.getExecutionContext();
39 if (!executionContext) 39 if (!executionContext)
40 return nullptr; 40 return nullptr;
41 if (executionContext->isDocument()) 41 if (executionContext->isDocument())
42 return toDocument(executionContext); 42 return toDocument(executionContext);
43 if (LocalDOMWindow* executingWindow = executionContext->executingWindow()) 43 if (LocalDOMWindow* executingWindow = executionContext->executingWindow())
44 return executingWindow->document(); 44 return executingWindow->document();
45 return nullptr; 45 return nullptr;
46 } 46 }
47 47
48 void OriginsUsingFeatures::countOriginOrIsolatedWorldHumanReadableName(const Scr iptState* scriptState, EventTarget& target, Feature feature) 48 void OriginsUsingFeatures::countOriginOrIsolatedWorldHumanReadableName(const Scr iptState* scriptState, EventTarget& target, Feature feature)
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 Platform::current()->recordRappor("PowerfulFeatureUse.Host.ApplicationCa cheAPI.Insecure", origin); 164 Platform::current()->recordRappor("PowerfulFeatureUse.Host.ApplicationCa cheAPI.Insecure", origin);
165 } 165 }
166 166
167 void OriginsUsingFeatures::Value::recordNameToRappor(const String& name) 167 void OriginsUsingFeatures::Value::recordNameToRappor(const String& name)
168 { 168 {
169 if (get(Feature::EventPath)) 169 if (get(Feature::EventPath))
170 Platform::current()->recordRappor("WebComponents.EventPath.Extensions", name); 170 Platform::current()->recordRappor("WebComponents.EventPath.Extensions", name);
171 } 171 }
172 172
173 } // namespace blink 173 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/Location.cpp ('k') | third_party/WebKit/Source/core/frame/RemoteDOMWindow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698