Title: [87442] trunk/Source/WebCore
Revision
87442
Author
je...@apple.com
Date
2011-05-26 15:43:51 -0700 (Thu, 26 May 2011)

Log Message

Fullscreen content is sometimes obscured by taskbar (which even covers up the "exit fullscreen" button)
https://bugs.webkit.org/show_bug.cgi?id=61569
<rdar://problem/9454315>

Reviewed by Steve Falkenburg.

Normally, when the background fullscreen window is animated in, the Windows taskbar will be hidden, but this doesn't always work for some reason.
Workaround this issue by setting the real fullscreen window to be a topmost window.

* platform/graphics/win/FullScreenController.cpp:
(FullScreenController::Private::fullscreenClientWndProc): Exit fullscreen when m_fullScreenWindow is deactivated.
(FullScreenController::enterFullScreenRepaintCompleted): Make m_fullScreenWindow a topmost window before animating it in to ensure the taskbar is hidden.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (87441 => 87442)


--- trunk/Source/WebCore/ChangeLog	2011-05-26 22:43:07 UTC (rev 87441)
+++ trunk/Source/WebCore/ChangeLog	2011-05-26 22:43:51 UTC (rev 87442)
@@ -1,3 +1,18 @@
+2011-05-26  Jeff Miller  <je...@apple.com>
+
+        Reviewed by Steve Falkenburg.
+
+        Fullscreen content is sometimes obscured by taskbar (which even covers up the "exit fullscreen" button)
+        https://bugs.webkit.org/show_bug.cgi?id=61569
+        <rdar://problem/9454315>
+
+        Normally, when the background fullscreen window is animated in, the Windows taskbar will be hidden, but this doesn't always work for some reason.
+        Workaround this issue by setting the real fullscreen window to be a topmost window.
+
+        * platform/graphics/win/FullScreenController.cpp:
+        (FullScreenController::Private::fullscreenClientWndProc): Exit fullscreen when m_fullScreenWindow is deactivated.
+        (FullScreenController::enterFullScreenRepaintCompleted): Make m_fullScreenWindow a topmost window before animating it in to ensure the taskbar is hidden.
+
 2011-05-26  James Robinson  <jam...@chromium.org>
 
         Reviewed by Darin Fisher.

Modified: trunk/Source/WebCore/platform/graphics/win/FullScreenController.cpp (87441 => 87442)


--- trunk/Source/WebCore/platform/graphics/win/FullScreenController.cpp	2011-05-26 22:43:07 UTC (rev 87441)
+++ trunk/Source/WebCore/platform/graphics/win/FullScreenController.cpp	2011-05-26 22:43:51 UTC (rev 87442)
@@ -84,6 +84,11 @@
         if (m_client->fullScreenClientWindow())
             ::SetWindowPos(m_client->fullScreenClientWindow(), 0, 0, 0, m_fullScreenFrame.width(), m_fullScreenFrame.height(), SWP_NOREPOSITION  | SWP_NOMOVE);
         break;
+    case WM_ACTIVATE:
+        // Because m_fullScreenWindow is a topmost window, we need to exit full screen explicitly when it's deactivated.
+        if (!wParam && m_fullScreenWindow && (hwnd == m_fullScreenWindow->hwnd()))
+            m_controller->exitFullScreen();
+        break;
     case WM_KEYDOWN:
         if (wParam == VK_ESCAPE) {
             m_controller->exitFullScreen();
@@ -152,6 +157,9 @@
         return;
     m_private->m_isEnteringFullScreen = false;
 
+    // Normally, when the background fullscreen window is animated in, the Windows taskbar will be hidden, but this doesn't always work for some reason.
+    // Setting the real fullscreen window to be a topmost window will force the taskbar to be hidden when we call AnimateWindow() below if it wasn't before.
+    ::SetWindowPos(m_private->m_fullScreenWindow->hwnd(), HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE);
     ::AnimateWindow(m_private->m_fullScreenWindow->hwnd(), kFullScreenAnimationDuration, AW_BLEND | AW_ACTIVATE);
 }
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to