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

Unified Diff: Source/core/html/HTMLVideoElement.cpp

Issue 31203002: Add UseCounters for prefixed HTMLVideoElement APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/HTMLVideoElement.h ('k') | Source/core/page/UseCounter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLVideoElement.cpp
diff --git a/Source/core/html/HTMLVideoElement.cpp b/Source/core/html/HTMLVideoElement.cpp
index 5bea9764c204f789445916db0b3b813f14f7ee40..d63869f33bce8f4d5f6c88e8aa0b974c70799693 100644
--- a/Source/core/html/HTMLVideoElement.cpp
+++ b/Source/core/html/HTMLVideoElement.cpp
@@ -219,8 +219,10 @@ bool HTMLVideoElement::hasAvailableVideoFrame() const
return player()->hasVideo() && player()->readyState() >= MediaPlayer::HaveCurrentData;
}
-void HTMLVideoElement::webkitEnterFullscreen(ExceptionState& es)
+void HTMLVideoElement::webkitEnterFullscreen(ExceptionState& es, UseCounter::Feature feature)
{
+ UseCounter::count(document(), feature);
+
if (isFullscreen())
return;
@@ -234,19 +236,22 @@ void HTMLVideoElement::webkitEnterFullscreen(ExceptionState& es)
enterFullscreen();
}
-void HTMLVideoElement::webkitExitFullscreen()
+void HTMLVideoElement::webkitExitFullscreen(UseCounter::Feature feature)
{
+ UseCounter::count(document(), feature);
if (isFullscreen())
exitFullscreen();
}
bool HTMLVideoElement::webkitSupportsFullscreen()
{
+ UseCounter::count(document(), UseCounter::PrefixedVideoSupportsFullscreen);
return supportsFullscreen();
}
bool HTMLVideoElement::webkitDisplayingFullscreen()
{
+ UseCounter::count(document(), UseCounter::PrefixedVideoDisplayingFullscreen);
return isFullscreen();
}
@@ -259,6 +264,8 @@ void HTMLVideoElement::didMoveToNewDocument(Document& oldDocument)
unsigned HTMLVideoElement::webkitDecodedFrameCount() const
{
+ UseCounter::count(document(), UseCounter::PrefixedVideoDecodedFrameCount);
+
if (!player())
return 0;
@@ -267,6 +274,8 @@ unsigned HTMLVideoElement::webkitDecodedFrameCount() const
unsigned HTMLVideoElement::webkitDroppedFrameCount() const
{
+ UseCounter::count(document(), UseCounter::PrefixedVideoDroppedFrameCount);
+
if (!player())
return 0;
« no previous file with comments | « Source/core/html/HTMLVideoElement.h ('k') | Source/core/page/UseCounter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698