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

Side by Side Diff: third_party/WebKit/Source/core/testing/WorkerInternals.cpp

Issue 2586863002: Worker: Enable UseCounter for SharedWorkerGlobalScope (Closed)
Patch Set: simplify Created 3 years, 10 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/testing/WorkerInternals.h" 5 #include "core/testing/WorkerInternals.h"
6 6
7 #include "bindings/core/v8/ScriptState.h"
8 #include "core/frame/Deprecation.h"
9 #include "core/frame/UseCounter.h"
7 #include "core/testing/OriginTrialsTest.h" 10 #include "core/testing/OriginTrialsTest.h"
8 11
9 namespace blink { 12 namespace blink {
10 13
11 WorkerInternals::~WorkerInternals() {} 14 WorkerInternals::~WorkerInternals() {}
12 15
13 WorkerInternals::WorkerInternals() {} 16 WorkerInternals::WorkerInternals() {}
14 17
15 OriginTrialsTest* WorkerInternals::originTrialsTest() const { 18 OriginTrialsTest* WorkerInternals::originTrialsTest() const {
16 return OriginTrialsTest::create(); 19 return OriginTrialsTest::create();
17 } 20 }
18 21
22 void WorkerInternals::countFeature(ScriptState* scriptState, uint32_t feature) {
23 UseCounter::count(scriptState->getExecutionContext(),
24 static_cast<UseCounter::Feature>(feature));
25 }
26
27 void WorkerInternals::countDeprecation(ScriptState* scriptState,
28 uint32_t feature) {
29 Deprecation::countDeprecation(scriptState->getExecutionContext(),
30 static_cast<UseCounter::Feature>(feature));
31 }
32
19 } // namespace blink 33 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/testing/WorkerInternals.h ('k') | third_party/WebKit/Source/core/testing/WorkerInternals.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698