• Brian Liu Xu's avatar
    Dismiss open tooltips when window is minimized · c11b932f
    Brian Liu Xu authored
    Hides tooltips when windows are hidden or minimized on Windows.
    
    Previously, when a browser window was minimized by the OS, tooltips
    would stay open on top of other windows because they did not receive an
    event that the mouse left the window. This was due to a race condition
    between the minimize message and the WM_MOUSELEAVE message. Since Aura
    first receives the minimize message and makes the Aura window not
    "visible", the subsequent mouse exit event was thus rejected by the Aura
    window. Consequently, tooltips would stick around indefinitely until the
    window was restored and interacted with.
    
    To fix this, we make the tooltip controller respond to the
    WM_WINDOWPOSCHANGED message (which is also sent to us when the window is
    minimizing) by explicitly hiding the tooltip.
    
    Bug: 724538
    Change-Id: I9e8a60e6de943230708b12f3a05b8ee03c27e54a
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2241631Reviewed-by: default avatarScott Violet <sky@chromium.org>
    Commit-Queue: Brian Liu Xu <brx@microsoft.com>
    Cr-Commit-Position: refs/heads/master@{#777994}
    c11b932f
tooltip_controller.cc 14.1 KB