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

Unified Diff: third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp

Issue 2535093003: Worker: Connect UseCounter to workers and worklets (Closed)
Patch Set: remove 'const' qualifiers Created 4 years 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp
diff --git a/third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp b/third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp
index 1f787aa1030e0eaf51d549c5f9a25559122d9831..f017b2f0a0105d6190f48991ea1424391747d9a1 100644
--- a/third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp
+++ b/third_party/WebKit/Source/core/workers/MainThreadWorkletGlobalScope.cpp
@@ -6,6 +6,7 @@
#include "bindings/core/v8/ScriptSourceCode.h"
#include "bindings/core/v8/WorkerOrWorkletScriptController.h"
+#include "core/frame/Deprecation.h"
#include "core/frame/FrameConsole.h"
#include "core/frame/LocalFrame.h"
#include "core/inspector/MainThreadDebugger.h"
@@ -23,6 +24,20 @@ MainThreadWorkletGlobalScope::MainThreadWorkletGlobalScope(
MainThreadWorkletGlobalScope::~MainThreadWorkletGlobalScope() {}
+void MainThreadWorkletGlobalScope::countFeature(UseCounter::Feature feature) {
+ // TODO(nhiroki): Support UseCounter for main thread worklets. A parent
+ // document is on the same thread, so just record API use in the document's
+ // UseCounter (https://crbug.com/667357).
+}
+
+void MainThreadWorkletGlobalScope::countDeprecation(
+ UseCounter::Feature feature) {
+ addDeprecationMessage(feature);
+ // TODO(nhiroki): Support UseCounter for main thread worklets. A parent
+ // document is on the same thread, so just record API use in the document's
+ // UseCounter (https://crbug.com/667357).
+}
+
WorkerThread* MainThreadWorkletGlobalScope::thread() const {
NOTREACHED();
return nullptr;

Powered by Google App Engine
This is Rietveld 408576698