Implement rect-based hit-test data provider for Exo |
|||||
Issue descriptionWe need ability to target Exo windows that have hit-test area different from the window bounds. Exo uses several classes, all called CustomWindowTargeter and all subclasses of WindowTargeter: - exo::Surface::CustomWindowTargeter - exo::SurfaceTreeHost::CustomWindowTargeter - exo::ShellSurface::CustomWindowTargeter Surface::state_.input_region can be used to collect all rects in it, then send to Viz similar to what HitTestDataProviderAura [1] is doing for Aura windows with shapes using ShapedAppWindowTargeter [2]. exo::Surface::CustomWindowTargeter is also used to filter stylus events so we may need an additional flag similar to kHitTestMouse and kHitTestTouch [3]. Test with --use-viz-hit-test and an Exo window that has a hit-test region defined. [1] https://cs.chromium.org/chromium/src/ui/aura/hit_test_data_provider_aura.h?type=cs&sq=package:chromium&l=19 [2] https://cs.chromium.org/chromium/src/chrome/browser/ui/views/apps/shaped_app_window_targeter.cc?type=cs&l=17 [3] - https://cs.chromium.org/chromium/src/services/viz/public/interfaces/hit_test/hit_test_region_list.mojom?type=cs&q=kHitTestMouse&sq=package:chromium&l=28
,
Sep 27 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b921f3fc6dba79c3af2c04311e54b88ec34c3ab0 commit b921f3fc6dba79c3af2c04311e54b88ec34c3ab0 Author: Peng Huang <penghuang@chromium.org> Date: Wed Sep 27 20:01:23 2017 exo: send surface's input region to mus The surface input region doesn't work in mus and mash. This CL implements WindowTargeter::GetExtraHitTestShapeRects() for exo::Surface::window_. In mus and mash, this function will be called and returned hittest rects will be sent to mus. Bug: 766174 Change-Id: I67dc04cc331f0174ff3390920c3de98c00100df5 Reviewed-on: https://chromium-review.googlesource.com/685277 Commit-Queue: Peng Huang <penghuang@chromium.org> Reviewed-by: David Reveman <reveman@chromium.org> Cr-Commit-Position: refs/heads/master@{#504758} [modify] https://crrev.com/b921f3fc6dba79c3af2c04311e54b88ec34c3ab0/components/exo/surface.cc [modify] https://crrev.com/b921f3fc6dba79c3af2c04311e54b88ec34c3ab0/components/exo/surface.h [modify] https://crrev.com/b921f3fc6dba79c3af2c04311e54b88ec34c3ab0/components/exo/surface_unittest.cc
,
Sep 27 2017
,
Jan 22 2018
,
Jan 23 2018
,
Feb 26 2018
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by varkha@chromium.org
, Sep 19 2017