
Top Chrome WebUIs are expected to behave like views UIs, where currently a big difference lies in handling mouse events in inactive windows. While views UIs allow hover effects and clicks to pass through when the window is inactive, Top Chrome WebUIs did not. This patch allows Top Chrome WebUIs to accept mouse events when the host window is inactive. Specifically, mouse move and click event are handled with subtle differences: * mouse move: accepts the event if the application is active (the content window could be inactive). * mouse click: always accepts the event. Note that, the mouse move behavior aligns with views UI, but this is not the behavior of other native macOS apps (e.g Notes, Safari), where move events are also always handled in the non-content area. A new method, acceptsMouseEventsOption, is added to RenderWidgetHostViewMacDelegate. It returns an AcceptMouseEventsOption enum of three possible options: * kAcceptMouseEventsInActiveWindow * kAcceptMouseEventsInActiveApp * kAcceptMouseEventsAlways For render widgets that host Top Chrome WebUIs, the browser now returns kAcceptMouseEventsInActiveApp, allowing interaction with inactive windows within an active app. This change applies to both trusted and untrusted Top Chrome WebUIs. Bug: 40791625, 338127521 Change-Id: Ie9d31afa202e7ee5215f3be5746c3c84aa7577da Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5516009 Reviewed-by: Avi Drissman <avi@chromium.org> Commit-Queue: Keren Zhu <kerenzhu@chromium.org> Cr-Commit-Position: refs/heads/main@{#1297056}
Chromium
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone
! Instead,
follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure.
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.