Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(340)

Issue 2535943002: Fix event targeting for overlay scrollbar thumbs (in native UI). (Closed)

Created:
4 years ago by tdanderson
Modified:
4 years ago
Reviewers:
CC:
chromium-reviews
Target Ref:
refs/pending/branch-heads/2924
Project:
chromium
Visibility:
Public.

Description

Fix event targeting for overlay scrollbar thumbs (in native UI). Views with layers are targeted based on their layer's transform rather than their local coordinates. See View::GetTransform(). Hence the thumb did not receive events until the translated area was hovered. To resolve this, make the thumb 11 + 4 = 15 dp wide all the time, and just slide back and forth so that 4dp is off the left or 4dp is off the right of the 11dp track, making sure the thumb always covers the whole track (it won't extend beyond visually or in terms of event handling because of the track's layer clipping). BUG=666798 Review-Url: https://codereview.chromium.org/2520433003 Cr-Commit-Position: refs/heads/master@{#433664} (cherry picked from commit 03722d39ae28885ebd6de91429325776c77da2a7) Committed: https://chromium.googlesource.com/chromium/src/+/045e98625ab0fed012c6fdfd7fb13c9194d43c8e

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+53 lines, -28 lines) Patch
M ui/views/controls/scroll_view_unittest.cc View 2 chunks +3 lines, -6 lines 0 comments Download
M ui/views/controls/scrollbar/base_scroll_bar.h View 1 chunk +3 lines, -1 line 0 comments Download
M ui/views/controls/scrollbar/base_scroll_bar.cc View 3 chunks +11 lines, -8 lines 0 comments Download
M ui/views/controls/scrollbar/cocoa_scroll_bar.mm View 2 chunks +2 lines, -1 line 0 comments Download
M ui/views/controls/scrollbar/overlay_scroll_bar.h View 1 chunk +2 lines, -0 lines 0 comments Download
M ui/views/controls/scrollbar/overlay_scroll_bar.cc View 6 chunks +30 lines, -11 lines 0 comments Download
M ui/views/controls/scrollbar/scroll_bar_views.cc View 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 2 (1 generated)
tdanderson
4 years ago (2016-11-28 19:45:13 UTC) #2
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as
045e98625ab0fed012c6fdfd7fb13c9194d43c8e (tree was closed).

Powered by Google App Engine
This is Rietveld 408576698