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

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

Issue 2034963002: Rename InkDropHover to InkDropHighlight (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix gyp file 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
« no previous file with comments | « ui/views/controls/button/custom_button.h ('k') | ui/views/controls/button/label_button.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 62f048173c68b2de35b20602c71f909c42275b17..0d9365c76119fc9b9583721e6065c67d1f770b5b 100644
--- a/ui/views/controls/button/custom_button.cc
+++ b/ui/views/controls/button/custom_button.cc
@@ -13,7 +13,7 @@
#include "ui/gfx/color_palette.h"
#include "ui/native_theme/native_theme.h"
#include "ui/views/animation/ink_drop_delegate.h"
-#include "ui/views/animation/ink_drop_hover.h"
+#include "ui/views/animation/ink_drop_highlight.h"
#include "ui/views/controls/button/blue_button.h"
#include "ui/views/controls/button/checkbox.h"
#include "ui/views/controls/button/image_button.h"
@@ -136,7 +136,7 @@ void CustomButton::OnEnabledChanged() {
SetState(STATE_DISABLED);
if (ink_drop_delegate())
- ink_drop_delegate()->SetHovered(ShouldShowInkDropHover());
+ ink_drop_delegate()->SetHovered(ShouldShowInkDropHighlight());
}
const char* CustomButton::GetClassName() const {
@@ -354,8 +354,9 @@ void CustomButton::VisibilityChanged(View* starting_from, bool visible) {
SetState(visible && ShouldEnterHoveredState() ? STATE_HOVERED : STATE_NORMAL);
}
-std::unique_ptr<InkDropHover> CustomButton::CreateInkDropHover() const {
- return ShouldShowInkDropHover() ? Button::CreateInkDropHover() : nullptr;
+std::unique_ptr<InkDropHighlight> CustomButton::CreateInkDropHighlight() const {
+ return ShouldShowInkDropHighlight() ? Button::CreateInkDropHighlight()
+ : nullptr;
}
SkColor CustomButton::GetInkDropBaseColor() const {
@@ -430,7 +431,7 @@ bool CustomButton::ShouldEnterPushedState(const ui::Event& event) {
return IsTriggerableEvent(event);
}
-bool CustomButton::ShouldShowInkDropHover() const {
+bool CustomButton::ShouldShowInkDropHighlight() const {
return enabled() && !InDrag() &&
(IsMouseHovered() || (ShouldShowInkDropForFocus() && HasFocus()));
}
« no previous file with comments | « ui/views/controls/button/custom_button.h ('k') | ui/views/controls/button/label_button.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698