Chromium Code Reviews| Index: chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc |
| diff --git a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc |
| index 659cf24d630d5bb9650c000ed3693d773bb1bf91..95c7cae71e2eadc4594a2324372444789341cad1 100644 |
| --- a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc |
| +++ b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc |
| @@ -79,6 +79,7 @@ |
| #include "ui/gfx/canvas.h" |
| #include "ui/gfx/color_utils.h" |
| #include "ui/gfx/favicon_size.h" |
| +#include "ui/gfx/geometry/insets.h" |
| #include "ui/gfx/geometry/rect.h" |
| #include "ui/gfx/image/image_skia_operations.h" |
| #include "ui/gfx/paint_vector_icon.h" |
| @@ -165,9 +166,11 @@ gfx::ImageSkia* GetImageSkiaNamed(int id) { |
| return ui::ResourceBundle::GetSharedInstance().GetImageSkiaNamed(id); |
| } |
| +const gfx::Insets kInkDropInsets(1, 0); |
| + |
| gfx::Rect CalculateInkDropBounds(const gfx::Size& size) { |
|
bruthig
2016/11/28 22:13:45
:( I kind of wish I had left myself a comment as t
mohsen
2016/11/29 00:07:12
Apparently, this is because https://crbug.com/5953
bruthig
2016/11/29 01:37:48
lgtm, thx!
|
| gfx::Rect ink_drop_bounds(size); |
| - ink_drop_bounds.Inset(0, 1); |
| + ink_drop_bounds.Inset(kInkDropInsets); |
| return ink_drop_bounds; |
| } |
| @@ -225,7 +228,7 @@ class BookmarkButtonBase : public views::LabelButton { |
| std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override { |
| return base::MakeUnique<views::FloodFillInkDropRipple>( |
| - CalculateInkDropBounds(size()), GetInkDropCenterBasedOnLastEvent(), |
| + size(), kInkDropInsets, GetInkDropCenterBasedOnLastEvent(), |
| GetInkDropBaseColor(), ink_drop_visible_opacity()); |
| } |
| @@ -348,7 +351,7 @@ class BookmarkMenuButtonBase : public views::MenuButton { |
| std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override { |
| return base::MakeUnique<views::FloodFillInkDropRipple>( |
| - CalculateInkDropBounds(size()), GetInkDropCenterBasedOnLastEvent(), |
| + size(), kInkDropInsets, GetInkDropCenterBasedOnLastEvent(), |
| GetInkDropBaseColor(), ink_drop_visible_opacity()); |
| } |