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

Unified Diff: chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc

Issue 2480203002: ui: Cleanup class/struct forward declarations (Closed)
Patch Set: Sync CL to position 430550 Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 a7a869c916791afee8edbd84727a692e96ca2f6a..ec0a26ef567b0f0cc84466e80de9c5f478619ddc 100644
--- a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
+++ b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
@@ -89,6 +89,7 @@
#include "ui/resources/grit/ui_resources.h"
#include "ui/views/animation/flood_fill_ink_drop_ripple.h"
#include "ui/views/animation/ink_drop_highlight.h"
+#include "ui/views/animation/ink_drop_impl.h"
#include "ui/views/button_drag_utils.h"
#include "ui/views/controls/button/label_button.h"
#include "ui/views/controls/button/label_button_border.h"
@@ -214,6 +215,11 @@ class BookmarkButtonBase : public views::LabelButton {
event_utils::IsPossibleDispositionEvent(e);
}
+ // LabelButton:
+ std::unique_ptr<views::InkDrop> CreateInkDrop() override {
+ return CreateDefaultFloodFillInkDropImpl();
+ }
+
std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override {
return base::MakeUnique<views::FloodFillInkDropRipple>(
CalculateInkDropBounds(size()), GetInkDropCenterBasedOnLastEvent(),
@@ -222,9 +228,6 @@ class BookmarkButtonBase : public views::LabelButton {
std::unique_ptr<views::InkDropHighlight> CreateInkDropHighlight()
const override {
- if (!ShouldShowInkDropHighlight())
- return nullptr;
-
const gfx::Rect bounds = CalculateInkDropBounds(size());
return base::MakeUnique<views::InkDropHighlight>(
bounds.size(), 0, gfx::RectF(bounds).CenterPoint(),
@@ -313,6 +316,11 @@ class BookmarkMenuButtonBase : public views::MenuButton {
SetFocusPainter(nullptr);
}
+ // MenuButton:
+ std::unique_ptr<views::InkDrop> CreateInkDrop() override {
+ return CreateDefaultFloodFillInkDropImpl();
+ }
+
std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override {
return base::MakeUnique<views::FloodFillInkDropRipple>(
CalculateInkDropBounds(size()), GetInkDropCenterBasedOnLastEvent(),
@@ -321,9 +329,6 @@ class BookmarkMenuButtonBase : public views::MenuButton {
std::unique_ptr<views::InkDropHighlight> CreateInkDropHighlight()
const override {
- if (!ShouldShowInkDropHighlight())
- return nullptr;
-
const gfx::Rect bounds = CalculateInkDropBounds(size());
return base::MakeUnique<views::InkDropHighlight>(
bounds.size(), 0, gfx::RectF(bounds).CenterPoint(),
@@ -1595,8 +1600,8 @@ void BookmarkBarView::Init() {
UpdateBookmarksSeparatorVisibility();
instructions_ = new BookmarkBarInstructionsView(this);
- instructions_->SetBorder(views::Border::CreateEmptyBorder(
- kButtonPaddingVertical, 0, kButtonPaddingVertical, 0));
+ instructions_->SetBorder(views::CreateEmptyBorder(kButtonPaddingVertical, 0,
+ kButtonPaddingVertical, 0));
AddChildView(instructions_);
set_context_menu_controller(this);

Powered by Google App Engine
This is Rietveld 408576698