Skip to content

Commit

Permalink
[ChromeRefresh2023] Focus Ring modifications for checkbox
Browse files Browse the repository at this point in the history
Bug: 1417057
Change-Id: Iff6eab9b689251c74d62f6a6601900ec6798d203
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4289701
Commit-Queue: Elaine Chien <elainechien@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1110512}
  • Loading branch information
Elaine Chien authored and Chromium LUCI CQ committed Feb 27, 2023
1 parent e529457 commit 878d18f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ui/views/controls/button/checkbox.cc
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,11 @@ void Checkbox::OnThemeChanged() {
SkPath Checkbox::GetFocusRingPath() const {
SkPath path;
gfx::Rect bounds = image()->GetMirroredContentsBounds();
bounds.Inset(1);
// Don't add extra insets in the ChromeRefresh case so that the focus ring can
// be drawn in the ChromeRefresh style.
if (!features::IsChromeRefresh2023()) {
bounds.Inset(1);
}
path.addRect(RectToSkRect(bounds));
return path;
}
Expand Down

0 comments on commit 878d18f

Please sign in to comment.