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

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

Issue 2041033002: Moved ButtonInkDropDelegate logic into InkDropHostView and deleted InkDropDelegates. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed merge conflict in custom_button.cc Created 4 years, 6 months 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 f2e934ea7c2549f47dd0dbfb2a38e51ce5b5f77f..57f2168c0db379b1bd1928321a53a75300a51dfb 100644
--- a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
+++ b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
@@ -95,7 +95,6 @@
#include "ui/gfx/text_elider.h"
#include "ui/gfx/vector_icons_public.h"
#include "ui/resources/grit/ui_resources.h"
-#include "ui/views/animation/button_ink_drop_delegate.h"
#include "ui/views/animation/flood_fill_ink_drop_ripple.h"
#include "ui/views/animation/ink_drop_highlight.h"
#include "ui/views/button_drag_utils.h"
@@ -206,8 +205,7 @@ class BookmarkButtonBase : public views::LabelButton {
const base::string16& title)
: LabelButton(listener, title) {
SetElideBehavior(kElideBehavior);
- set_ink_drop_delegate(
- base::WrapUnique(new views::ButtonInkDropDelegate(this, this)));
+ SetHasInkDrop(true);
set_has_ink_drop_action_on_click(true);
show_animation_.reset(new gfx::SlideAnimation(this));
if (!animations_enabled) {
@@ -333,8 +331,7 @@ class BookmarkMenuButtonBase : public views::MenuButton {
views::MenuButtonListener* menu_button_listener,
bool show_menu_marker)
: MenuButton(title, menu_button_listener, show_menu_marker) {
- set_ink_drop_delegate(
- base::WrapUnique(new views::ButtonInkDropDelegate(this, this)));
+ SetHasInkDrop(true);
}
std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override {
@@ -395,7 +392,7 @@ class BookmarkFolderButton : public BookmarkMenuButtonBase {
// TODO(bruthig): The ACTION_PENDING triggering logic should be in
// MenuButton::OnPressed() however there is a bug with the pressed state
// logic in MenuButton. See http://crbug.com/567252.
- ink_drop_delegate()->OnAction(views::InkDropState::ACTION_PENDING);
+ AnimateInkDrop(views::InkDropState::ACTION_PENDING);
}
return MenuButton::OnMousePressed(event);
}
« no previous file with comments | « chrome/browser/ui/views/bar_control_button.cc ('k') | chrome/browser/ui/views/download/download_item_view_md.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698