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

Side by Side Diff: third_party/WebKit/Source/core/frame/UseCounter.h

Issue 2535093003: Worker: Connect UseCounter to workers and worklets (Closed)
Patch Set: 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google, Inc. All rights reserved. 2 * Copyright (C) 2012 Google, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 1375 matching lines...) Expand 10 before | Expand all | Expand 10 after
1386 // Add new features immediately above this line. Don't change assigned 1386 // Add new features immediately above this line. Don't change assigned
1387 // numbers of any item, and don't reuse removed slots. 1387 // numbers of any item, and don't reuse removed slots.
1388 // Also, run update_use_counter_feature_enum.py in 1388 // Also, run update_use_counter_feature_enum.py in
1389 // chromium/src/tools/metrics/histograms/ to update the UMA mapping. 1389 // chromium/src/tools/metrics/histograms/ to update the UMA mapping.
1390 NumberOfFeatures, // This enum value must be last. 1390 NumberOfFeatures, // This enum value must be last.
1391 }; 1391 };
1392 1392
1393 // "count" sets the bit for this feature to 1. Repeated calls are ignored. 1393 // "count" sets the bit for this feature to 1. Repeated calls are ignored.
1394 static void count(const Frame*, Feature); 1394 static void count(const Frame*, Feature);
1395 static void count(const Document&, Feature); 1395 static void count(const Document&, Feature);
1396 // This doesn't count for ExecutionContexts for shared workers and service
1397 // workers.
1398 static void count(const ExecutionContext*, Feature); 1396 static void count(const ExecutionContext*, Feature);
1399 // Use countIfNotPrivateScript() instead of count() if you don't want 1397 // Use countIfNotPrivateScript() instead of count() if you don't want
1400 // to count metrics in private scripts. You should use 1398 // to count metrics in private scripts. You should use
1401 // countIfNotPrivateScript() in a binding layer. 1399 // countIfNotPrivateScript() in a binding layer.
1402 static void countIfNotPrivateScript(v8::Isolate*, const Frame*, Feature); 1400 static void countIfNotPrivateScript(v8::Isolate*, const Frame*, Feature);
1403 static void countIfNotPrivateScript(v8::Isolate*, const Document&, Feature); 1401 static void countIfNotPrivateScript(v8::Isolate*, const Document&, Feature);
1404 static void countIfNotPrivateScript(v8::Isolate*, 1402 static void countIfNotPrivateScript(v8::Isolate*,
1405 const ExecutionContext*, 1403 const ExecutionContext*,
1406 Feature); 1404 Feature);
1407 1405
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
1463 // Tracks what features/properties need to be reported to the legacy 1461 // Tracks what features/properties need to be reported to the legacy
1464 // histograms. 1462 // histograms.
1465 BitVector m_featureBits; 1463 BitVector m_featureBits;
1466 BitVector m_CSSBits; 1464 BitVector m_CSSBits;
1467 } m_legacyCounter; 1465 } m_legacyCounter;
1468 }; 1466 };
1469 1467
1470 } // namespace blink 1468 } // namespace blink
1471 1469
1472 #endif // UseCounter_h 1470 #endif // UseCounter_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698