Changeset 55942 in webkit


Ignore:
Timestamp:
Mar 12, 2010 3:17:12 PM (14 years ago)
Author:
Beth Dakin
Message:

Fix for https://bugs.webkit.org/show_bug.cgi?id=33739 Fullscreen
video HUD stays on top when switching to another window (e.g. via
Alt-Tab)
-and corresponding-
<rdar://problem/7547574>

Reviewed by Adam Roben.

The HUD was always on top because it had the WS_EX_TOPMOST style.
So I removed the style and made m_videoWindow the owner of
m_hudWindow. This keeps m_hudWindow on top only when m_videoWindow
is the focused window.

  • FullscreenVideoController.cpp:

(FullscreenVideoController::exitFullscreen): ASSERT that movie()->exitFullscreen() also destroyed the hud.
(FullscreenVideoController::createHUDWindow):

Location:
trunk/WebKit/win
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit/win/ChangeLog

    r55941 r55942  
     12010-03-12  Beth Dakin  <bdakin@apple.com>
     2
     3        Reviewed by Adam Roben.
     4
     5        Fix for https://bugs.webkit.org/show_bug.cgi?id=33739 Fullscreen
     6        video HUD stays on top when switching to another window (e.g. via
     7        Alt-Tab)
     8        -and corresponding-
     9        <rdar://problem/7547574>
     10
     11        The HUD was always on top because it had the WS_EX_TOPMOST style.
     12        So I removed the style and made m_videoWindow the owner of
     13        m_hudWindow. This keeps m_hudWindow on top only when m_videoWindow
     14        is the focused window.
     15
     16        * FullscreenVideoController.cpp:
     17        (FullscreenVideoController::exitFullscreen): ASSERT that movie()->exitFullscreen() also destroyed the hud.
     18        (FullscreenVideoController::createHUDWindow):
     19
    1202010-03-12  Enrica Casucci  <enrica@apple.com>
    221
  • trunk/WebKit/win/FullscreenVideoController.cpp

    r54182 r55942  
    227227void FullscreenVideoController::exitFullscreen()
    228228{
     229    SetWindowLongPtr(m_hudWindow, 0, 0);
    229230    if (movie())
    230231        movie()->exitFullscreen();
    231232
     233    ASSERT(!IsWindow(m_hudWindow));
    232234    m_videoWindow = 0;
    233     SetWindowLongPtr(m_hudWindow, 0, 0);
    234     DestroyWindow(m_hudWindow);
    235235    m_hudWindow = 0;
    236236}
     
    369369    registerHUDWindowClass();
    370370
    371     m_hudWindow = CreateWindowEx(WS_EX_LAYERED | WS_EX_TRANSPARENT | WS_EX_TOPMOST | WS_EX_TOOLWINDOW,
     371    m_hudWindow = CreateWindowEx(WS_EX_LAYERED | WS_EX_TRANSPARENT | WS_EX_TOOLWINDOW,
    372372        fullscreenVideeoHUDWindowClassName, 0, WS_POPUP | WS_VISIBLE,
    373         m_hudPosition.x(), m_hudPosition.y(), 0, 0, 0, 0, gInstance, 0);
     373        m_hudPosition.x(), m_hudPosition.y(), 0, 0, m_videoWindow, 0, gInstance, 0);
    374374    ASSERT(::IsWindow(m_hudWindow));
    375375    SetWindowLongPtr(m_hudWindow, 0, reinterpret_cast<LONG_PTR>(this));
Note: See TracChangeset for help on using the changeset viewer.