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

Unified Diff: ui/views/animation/ink_drop_impl.cc

Issue 2720183002: [Views] Update ink drop for omnibox icons (Closed)
Patch Set: Removed CanProcessEventsWithinSubtree Created 3 years, 7 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/animation/ink_drop_impl.h ('k') | ui/views/animation/ink_drop_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/animation/ink_drop_impl.cc
diff --git a/ui/views/animation/ink_drop_impl.cc b/ui/views/animation/ink_drop_impl.cc
index d5a4d8a3ec5e54a7b6f6ffb1a79c1dc4698792da..8bf9a3cc31871a4d455d3b14468786f2a30addd3 100644
--- a/ui/views/animation/ink_drop_impl.cc
+++ b/ui/views/animation/ink_drop_impl.cc
@@ -603,16 +603,6 @@ InkDropImpl::~InkDropImpl() {
DestroyInkDropHighlight();
}
-void InkDropImpl::SetShowHighlightOnHover(bool show_highlight_on_hover) {
- show_highlight_on_hover_ = show_highlight_on_hover;
- highlight_state_->ShowOnHoverChanged();
-}
-
-void InkDropImpl::SetShowHighlightOnFocus(bool show_highlight_on_focus) {
- show_highlight_on_focus_ = show_highlight_on_focus;
- highlight_state_->ShowOnFocusChanged();
-}
-
void InkDropImpl::SetAutoHighlightMode(AutoHighlightMode auto_highlight_mode) {
// Exit the current state completely first in case state tear down accesses
// the current |highlight_state_factory_| instance.
@@ -667,6 +657,20 @@ void InkDropImpl::SetFocused(bool is_focused) {
highlight_state_->OnFocusChanged();
}
+bool InkDropImpl::IsHighlightFadingInOrVisible() const {
+ return highlight_ && highlight_->IsFadingInOrVisible();
+}
+
+void InkDropImpl::SetShowHighlightOnHover(bool show_highlight_on_hover) {
+ show_highlight_on_hover_ = show_highlight_on_hover;
+ highlight_state_->ShowOnHoverChanged();
+}
+
+void InkDropImpl::SetShowHighlightOnFocus(bool show_highlight_on_focus) {
+ show_highlight_on_focus_ = show_highlight_on_focus;
+ highlight_state_->ShowOnFocusChanged();
+}
+
void InkDropImpl::DestroyHiddenTargetedAnimations() {
if (ink_drop_ripple_ &&
(ink_drop_ripple_->target_ink_drop_state() == InkDropState::HIDDEN ||
@@ -733,15 +737,12 @@ void InkDropImpl::RemoveRootLayerFromHostIfNeeded() {
}
}
-bool InkDropImpl::IsHighlightFadingInOrVisible() const {
- return highlight_ && highlight_->IsFadingInOrVisible();
-}
-
// -----------------------------------------------------------------------------
// views::InkDropRippleObserver:
void InkDropImpl::AnimationStarted(InkDropState ink_drop_state) {
highlight_state_->AnimationStarted(ink_drop_state);
+ NotifyInkDropAnimationStarted();
}
void InkDropImpl::AnimationEnded(InkDropState ink_drop_state,
@@ -766,7 +767,9 @@ void InkDropImpl::AnimationEnded(InkDropState ink_drop_state,
// views::InkDropHighlightObserver:
void InkDropImpl::AnimationStarted(
- InkDropHighlight::AnimationType animation_type) {}
+ InkDropHighlight::AnimationType animation_type) {
+ NotifyInkDropAnimationStarted();
+}
void InkDropImpl::AnimationEnded(InkDropHighlight::AnimationType animation_type,
InkDropAnimationEndedReason reason) {
« no previous file with comments | « ui/views/animation/ink_drop_impl.h ('k') | ui/views/animation/ink_drop_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698