Chromium Code Reviews| Index: chrome/browser/ui/views/toolbar/toolbar_action_view.h |
| diff --git a/chrome/browser/ui/views/toolbar/toolbar_action_view.h b/chrome/browser/ui/views/toolbar/toolbar_action_view.h |
| index 73e607ea9ff9a132d245481fefa992bf65612711..16c1adc939695a96aafe4013de151dbe7f81a0c3 100644 |
| --- a/chrome/browser/ui/views/toolbar/toolbar_action_view.h |
| +++ b/chrome/browser/ui/views/toolbar/toolbar_action_view.h |
| @@ -9,6 +9,7 @@ |
| #include "chrome/browser/ui/views/toolbar/toolbar_action_view_delegate_views.h" |
| #include "content/public/browser/notification_observer.h" |
| #include "content/public/browser/notification_registrar.h" |
| +#include "ui/views/animation/ink_drop_host.h" |
| #include "ui/views/context_menu_controller.h" |
| #include "ui/views/controls/button/menu_button.h" |
| #include "ui/views/controls/button/menu_button_listener.h" |
| @@ -39,7 +40,8 @@ class ToolbarActionView : public views::MenuButton, |
| public ToolbarActionViewDelegateViews, |
| public views::MenuButtonListener, |
| public views::ContextMenuController, |
| - public content::NotificationObserver { |
| + public content::NotificationObserver, |
| + public views::InkDropHost { |
| public: |
| // Need DragController here because ToolbarActionView could be |
| // dragged/dropped. |
| @@ -108,9 +110,22 @@ class ToolbarActionView : public views::MenuButton, |
| views::MenuItemView* menu_for_testing() { return menu_; } |
| + // views::InkDropHost: |
|
Peter Kasting
2015/11/24 20:42:01
Place this above with the other override groups.
varkha
2015/11/24 21:50:44
Done.
|
| + void AddInkDropLayer(ui::Layer* ink_drop_layer) override; |
| + void RemoveInkDropLayer(ui::Layer* ink_drop_layer) override; |
| + |
| + protected: |
|
Peter Kasting
2015/11/24 20:42:01
Are there subclasses that actually call these? If
varkha
2015/11/24 21:50:44
Done.
|
| + // views::InkDropHost: |
| + gfx::Point CalculateInkDropCenter() const override; |
| + |
| + // views::View: |
|
Peter Kasting
2015/11/24 20:42:01
You don't directly subclass views::View. This sho
varkha
2015/11/24 21:50:44
Done.
|
| + views::InkDropDelegate* GetInkDropDelegate() const override; |
| + |
| private: |
| // views::MenuButton: |
| gfx::Size GetPreferredSize() const override; |
| + bool OnMousePressed(const ui::MouseEvent& event) override; |
| + void OnGestureEvent(ui::GestureEvent* event) override; |
| void OnDragDone() override; |
| void ViewHierarchyChanged( |
| const ViewHierarchyChangedDetails& details) override; |
| @@ -172,6 +187,9 @@ class ToolbarActionView : public views::MenuButton, |
| content::NotificationRegistrar registrar_; |
| + // Animation delegate for the ink drop ripple effect. |
| + scoped_ptr<views::InkDropDelegate> ink_drop_delegate_; |
| + |
| base::WeakPtrFactory<ToolbarActionView> weak_factory_; |
| DISALLOW_COPY_AND_ASSIGN(ToolbarActionView); |