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

Unified Diff: ui/views/controls/button/custom_button.cc

Issue 1390113006: Added material design mouse hover feedback support. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed pkasting@'s comments from patch set 13. Created 5 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: ui/views/controls/button/custom_button.cc
diff --git a/ui/views/controls/button/custom_button.cc b/ui/views/controls/button/custom_button.cc
index 61b595bbfeb2f059327527ad3c1ef18e76afb270..70d090241eefe4bfe6c146c45b3b9c468b7928c7 100644
--- a/ui/views/controls/button/custom_button.cc
+++ b/ui/views/controls/button/custom_button.cc
@@ -312,6 +312,13 @@ void CustomButton::AnimationProgressed(const gfx::Animation* animation) {
}
////////////////////////////////////////////////////////////////////////////////
+// CustomButton, views::InkDropConsumer implementation:
+
+bool CustomButton::ShouldShowInkDropHover() {
+ return enabled() && IsMouseHovered();
+}
+
+////////////////////////////////////////////////////////////////////////////////
// CustomButton, protected:
CustomButton::CustomButton(ButtonListener* listener)

Powered by Google App Engine
This is Rietveld 408576698