Adapt app list item focus bounds to account for ring stroke width
The app list item focus ring is painted using stroke width 2, within bounds specified by AppListConfig::grid_focus_size(). This fixes discrepancy between what app list config specifies and what actually gets painted using stroke width 2: * the bounds were painted so the stroke was centered on the focus ring bounds * app list config specifies the outer focus ring bounds For kMedium and kSmall app list config (where the top focus ring bounds match the app list item bounds), this caused the top focus ring to be painted using width 1 instead of required 2 (as the upper part of the ring stroke was clipped by the app list item bounds). This updates the focus ring bounds calculation in AppListItemView to account for the stroke size - the target focus ring bounds are inset by half the ring width. BUG=1014128 Change-Id: Ib605afdc4312214a2a6d6c7c46251dd6fbe46000 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1859578 Commit-Queue: Toni Baržić <tbarzic@chromium.org> Reviewed-by:Xiyuan Xia <xiyuan@chromium.org> Cr-Commit-Position: refs/heads/master@{#705732}
Showing
Please register or sign in to comment