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

Unified Diff: chrome/browser/ui/views/toolbar/toolbar_button.h

Issue 1298513003: Implemented prototype for new ink drop specs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments from patch set 10. Created 5 years, 3 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
« no previous file with comments | « chrome/browser/ui/views/toolbar/back_button.cc ('k') | chrome/browser/ui/views/toolbar/toolbar_button.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/toolbar/toolbar_button.h
diff --git a/chrome/browser/ui/views/toolbar/toolbar_button.h b/chrome/browser/ui/views/toolbar/toolbar_button.h
index c61d85cb07d293772c90469ebdd48de66cf8d1c3..f607a446475015b860253cf05b3bb0866b107a9d 100644
--- a/chrome/browser/ui/views/toolbar/toolbar_button.h
+++ b/chrome/browser/ui/views/toolbar/toolbar_button.h
@@ -6,6 +6,7 @@
#define CHROME_BROWSER_UI_VIEWS_TOOLBAR_TOOLBAR_BUTTON_H_
#include "base/memory/scoped_ptr.h"
+#include "ui/gfx/geometry/point.h"
#include "ui/views/animation/ink_drop_host.h"
#include "ui/views/context_menu_controller.h"
#include "ui/views/controls/button/button.h"
@@ -62,11 +63,9 @@ class ToolbarButton : public views::LabelButton,
void RemoveInkDropLayer(ui::Layer* ink_drop_layer) override;
protected:
- // Overridden from CustomButton. Returns true if the button should become
- // pressed when a user holds the mouse down over the button. For this
- // implementation, both left and right mouse buttons can trigger a change
- // to the PUSHED state.
+ // views::LabelButton:
bool ShouldEnterPushedState(const ui::Event& event) override;
+ void NotifyClick(const ui::Event& event) override;
// Returns if menu should be shown. Override this to change default behavior.
virtual bool ShouldShowMenu();
@@ -74,7 +73,8 @@ class ToolbarButton : public views::LabelButton,
// Function to show the dropdown menu.
virtual void ShowDropDownMenu(ui::MenuSourceType source_type);
- virtual void LayoutInkDrop();
+ // Returns the Point where the ink drop should be centered.
+ virtual gfx::Point CalculateInkDropCenter() const;
views::InkDropAnimationController* ink_drop_animation_controller() {
return ink_drop_animation_controller_.get();
« no previous file with comments | « chrome/browser/ui/views/toolbar/back_button.cc ('k') | chrome/browser/ui/views/toolbar/toolbar_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698