Title: [219569] trunk/Source
Revision
219569
Author
commit-qu...@webkit.org
Date
2017-07-17 12:22:30 -0700 (Mon, 17 Jul 2017)

Log Message

Add video fullscreen transition logging.
https://bugs.webkit.org/show_bug.cgi?id=174474

Patch by Jeremy Jones <jere...@apple.com> on 2017-07-17
Reviewed by Jer Noble.

Source/WebCore:

No new tests, because there is no functional change.

This change just adds logging.

* html/HTMLVideoElement.cpp:
(WebCore::HTMLVideoElement::webkitEnterFullscreen):
(WebCore::HTMLVideoElement::webkitExitFullscreen):
(WebCore::HTMLVideoElement::webkitSetPresentationMode):

Source/WebKit:

No functional change. Just adds logging.

* Platform/Logging.h:
* WebProcess/cocoa/WebVideoFullscreenManager.mm:
(WebKit::WebVideoFullscreenManager::enterVideoFullscreenForVideoElement):
(WebKit::WebVideoFullscreenManager::exitVideoFullscreenForVideoElement):
(WebKit::WebVideoFullscreenManager::exitVideoFullscreenToModeWithoutAnimation):
(WebKit::WebVideoFullscreenManager::didSetupFullscreen):
(WebKit::WebVideoFullscreenManager::didEnterFullscreen):
(WebKit::WebVideoFullscreenManager::didExitFullscreen):
(WebKit::WebVideoFullscreenManager::didCleanupFullscreen):
(WebKit::WebVideoFullscreenManager::setVideoLayerFrameFenced):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (219568 => 219569)


--- trunk/Source/WebCore/ChangeLog	2017-07-17 19:14:12 UTC (rev 219568)
+++ trunk/Source/WebCore/ChangeLog	2017-07-17 19:22:30 UTC (rev 219569)
@@ -1,3 +1,19 @@
+2017-07-17  Jeremy Jones  <jere...@apple.com>
+
+        Add video fullscreen transition logging.
+        https://bugs.webkit.org/show_bug.cgi?id=174474
+
+        Reviewed by Jer Noble.
+
+        No new tests, because there is no functional change.
+
+        This change just adds logging.
+
+        * html/HTMLVideoElement.cpp:
+        (WebCore::HTMLVideoElement::webkitEnterFullscreen):
+        (WebCore::HTMLVideoElement::webkitExitFullscreen):
+        (WebCore::HTMLVideoElement::webkitSetPresentationMode):
+
 2017-07-17  Chris Dumez  <cdu...@apple.com>
 
         click event does not dispatch to parent when child target stops hit testing after mousedown

Modified: trunk/Source/WebCore/html/HTMLVideoElement.cpp (219568 => 219569)


--- trunk/Source/WebCore/html/HTMLVideoElement.cpp	2017-07-17 19:14:12 UTC (rev 219568)
+++ trunk/Source/WebCore/html/HTMLVideoElement.cpp	2017-07-17 19:22:30 UTC (rev 219569)
@@ -308,6 +308,7 @@
 
 ExceptionOr<void> HTMLVideoElement::webkitEnterFullscreen()
 {
+    LOG(Media, "HTMLVideoElement::webkitEnterFullscreen(%p)", this);
     if (isFullscreen())
         return { };
 
@@ -322,6 +323,7 @@
 
 void HTMLVideoElement::webkitExitFullscreen()
 {
+    LOG(Media, "HTMLVideoElement::webkitExitFullscreen(%p)", this);
     if (isFullscreen())
         exitFullscreen();
 }
@@ -431,6 +433,7 @@
 
 void HTMLVideoElement::webkitSetPresentationMode(VideoPresentationMode mode)
 {
+    LOG(Media, "HTMLVideoElement::webkitSetPresentationMode(%p) - %d", this, mode);
     setFullscreenMode(toFullscreenMode(mode));
 }
 

Modified: trunk/Source/WebKit/ChangeLog (219568 => 219569)


--- trunk/Source/WebKit/ChangeLog	2017-07-17 19:14:12 UTC (rev 219568)
+++ trunk/Source/WebKit/ChangeLog	2017-07-17 19:22:30 UTC (rev 219569)
@@ -1,3 +1,23 @@
+2017-07-17  Jeremy Jones  <jere...@apple.com>
+
+        Add video fullscreen transition logging.
+        https://bugs.webkit.org/show_bug.cgi?id=174474
+
+        Reviewed by Jer Noble.
+
+        No functional change. Just adds logging.
+
+        * Platform/Logging.h:
+        * WebProcess/cocoa/WebVideoFullscreenManager.mm:
+        (WebKit::WebVideoFullscreenManager::enterVideoFullscreenForVideoElement):
+        (WebKit::WebVideoFullscreenManager::exitVideoFullscreenForVideoElement):
+        (WebKit::WebVideoFullscreenManager::exitVideoFullscreenToModeWithoutAnimation):
+        (WebKit::WebVideoFullscreenManager::didSetupFullscreen):
+        (WebKit::WebVideoFullscreenManager::didEnterFullscreen):
+        (WebKit::WebVideoFullscreenManager::didExitFullscreen):
+        (WebKit::WebVideoFullscreenManager::didCleanupFullscreen):
+        (WebKit::WebVideoFullscreenManager::setVideoLayerFrameFenced):
+
 2017-07-17  Konstantin Tokarev  <annu...@yandex.ru>
 
         [CMake] Create targets before WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS is called

Modified: trunk/Source/WebKit/Platform/Logging.h (219568 => 219569)


--- trunk/Source/WebKit/Platform/Logging.h	2017-07-17 19:14:12 UTC (rev 219568)
+++ trunk/Source/WebKit/Platform/Logging.h	2017-07-17 19:22:30 UTC (rev 219569)
@@ -43,6 +43,7 @@
 #define WEBKIT2_LOG_CHANNELS(M) \
     M(ContextMenu) \
     M(DragAndDrop) \
+    M(Fullscreen) \
     M(Gamepad) \
     M(IconDatabase) \
     M(IDB) \

Modified: trunk/Source/WebKit/WebProcess/cocoa/WebVideoFullscreenManager.mm (219568 => 219569)


--- trunk/Source/WebKit/WebProcess/cocoa/WebVideoFullscreenManager.mm	2017-07-17 19:14:12 UTC (rev 219568)
+++ trunk/Source/WebKit/WebProcess/cocoa/WebVideoFullscreenManager.mm	2017-07-17 19:22:30 UTC (rev 219569)
@@ -28,6 +28,7 @@
 #if (PLATFORM(IOS) && HAVE(AVKIT)) || (PLATFORM(MAC) && ENABLE(VIDEO_PRESENTATION_MODE))
 
 #import "Attachment.h"
+#import "Logging.h"
 #import "WebCoreArgumentCoders.h"
 #import "WebPage.h"
 #import "WebPlaybackSessionManager.h"
@@ -221,6 +222,7 @@
 {
     ASSERT(m_page);
     ASSERT(mode != HTMLMediaElementEnums::VideoFullscreenModeNone);
+    LOG(Fullscreen, "WebVideoFullscreenManager::enterVideoFullscreenForVideoElement(%p)", this);
 
     uint64_t contextId = m_playbackSessionManager->contextIdForMediaElement(videoElement);
     auto addResult = m_videoElements.add(&videoElement, contextId);
@@ -255,6 +257,7 @@
 
 void WebVideoFullscreenManager::exitVideoFullscreenForVideoElement(WebCore::HTMLVideoElement& videoElement)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::exitVideoFullscreenForVideoElement(%p)", this);
     ASSERT(m_page);
     ASSERT(m_videoElements.contains(&videoElement));
 
@@ -272,6 +275,8 @@
 
 void WebVideoFullscreenManager::exitVideoFullscreenToModeWithoutAnimation(WebCore::HTMLVideoElement& videoElement, WebCore::HTMLMediaElementEnums::VideoFullscreenMode targetMode)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::exitVideoFullscreenToModeWithoutAnimation(%p)", this);
+
 #if PLATFORM(MAC) && ENABLE(VIDEO_PRESENTATION_MODE)
     ASSERT(m_page);
     ASSERT(m_videoElements.contains(&videoElement));
@@ -316,6 +321,8 @@
 
 void WebVideoFullscreenManager::didSetupFullscreen(uint64_t contextId)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::didSetupFullscreen(%p, %x)", this, contextId);
+
     ASSERT(m_page);
     PlatformLayer* videoLayer = [CALayer layer];
 #ifndef NDEBUG
@@ -353,6 +360,8 @@
     
 void WebVideoFullscreenManager::didEnterFullscreen(uint64_t contextId)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::didEnterFullscreen(%p, %x)", this, contextId);
+
     RefPtr<WebVideoFullscreenModelVideoElement> model;
     RefPtr<WebVideoFullscreenInterfaceContext> interface;
     std::tie(model, interface) = ensureModelAndInterface(contextId);
@@ -377,6 +386,8 @@
 
 void WebVideoFullscreenManager::didExitFullscreen(uint64_t contextId)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::didExitFullscreen(%p, %x)", this, contextId);
+
     RefPtr<WebVideoFullscreenModelVideoElement> model;
     RefPtr<WebVideoFullscreenInterfaceContext> interface;
     std::tie(model, interface) = ensureModelAndInterface(contextId);
@@ -400,6 +411,8 @@
     
 void WebVideoFullscreenManager::didCleanupFullscreen(uint64_t contextId)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::didCleanupFullscreen(%p, %x)", this, contextId);
+
     RefPtr<WebVideoFullscreenModelVideoElement> model;
     RefPtr<WebVideoFullscreenInterfaceContext> interface;
     std::tie(model, interface) = ensureModelAndInterface(contextId);
@@ -444,6 +457,8 @@
     
 void WebVideoFullscreenManager::setVideoLayerFrameFenced(uint64_t contextId, WebCore::FloatRect bounds, IPC::Attachment fencePort)
 {
+    LOG(Fullscreen, "WebVideoFullscreenManager::setVideoLayerFrameFenced(%p, %x)", this, contextId);
+
     RefPtr<WebVideoFullscreenModelVideoElement> model;
     RefPtr<WebVideoFullscreenInterfaceContext> interface;
     std::tie(model, interface) = ensureModelAndInterface(contextId);
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to