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

Side by Side Diff: ui/views/animation/ink_drop_ripple.h

Issue 2250783002: Allow InkDropRipple to co-exist with highlight (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove EmptyInkDropRipple Created 4 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 unified diff | Download patch
« no previous file with comments | « ui/views/animation/ink_drop_impl_unittest.cc ('k') | ui/views/animation/ink_drop_ripple.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_ 5 #ifndef UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_
6 #define UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_ 6 #define UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "ui/gfx/geometry/point.h" 9 #include "ui/gfx/geometry/point.h"
10 #include "ui/views/animation/ink_drop_ripple_observer.h" 10 #include "ui/views/animation/ink_drop_ripple_observer.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 // animations are aborted. Events will be raised for the pending animations 71 // animations are aborted. Events will be raised for the pending animations
72 // as well as the transition to the ACTIVATED state. 72 // as well as the transition to the ACTIVATED state.
73 virtual void SnapToActivated(); 73 virtual void SnapToActivated();
74 74
75 // The root Layer that can be added in to a Layer tree. 75 // The root Layer that can be added in to a Layer tree.
76 virtual ui::Layer* GetRootLayer() = 0; 76 virtual ui::Layer* GetRootLayer() = 0;
77 77
78 // Returns true when the ripple is visible. This is different from checking if 78 // Returns true when the ripple is visible. This is different from checking if
79 // the ink_drop_state() == HIDDEN because the ripple may be visible while it 79 // the ink_drop_state() == HIDDEN because the ripple may be visible while it
80 // animates to the target HIDDEN state. 80 // animates to the target HIDDEN state.
81 virtual bool IsVisible() const = 0; 81 bool IsVisible();
82
83 // Returns true if this ripple is mutually exclusive with InkDropHighlight.
84 virtual bool OverridesHighlight() const = 0;
82 85
83 // Returns a test api to access internals of this. Default implmentations 86 // Returns a test api to access internals of this. Default implmentations
84 // should return nullptr and test specific subclasses can override to return 87 // should return nullptr and test specific subclasses can override to return
85 // an instance. 88 // an instance.
86 virtual test::InkDropRippleTestApi* GetTestApi(); 89 virtual test::InkDropRippleTestApi* GetTestApi();
87 90
88 protected: 91 protected:
89 // Animates the ripple from the |old_ink_drop_state| to the 92 // Animates the ripple from the |old_ink_drop_state| to the
90 // |new_ink_drop_state|. |observer| is added to all LayerAnimationSequence's 93 // |new_ink_drop_state|. |observer| is added to all LayerAnimationSequence's
91 // used if not null. 94 // used if not null.
(...skipping 25 matching lines...) Expand all
117 InkDropState target_ink_drop_state_; 120 InkDropState target_ink_drop_state_;
118 121
119 InkDropRippleObserver* observer_; 122 InkDropRippleObserver* observer_;
120 123
121 DISALLOW_COPY_AND_ASSIGN(InkDropRipple); 124 DISALLOW_COPY_AND_ASSIGN(InkDropRipple);
122 }; 125 };
123 126
124 } // namespace views 127 } // namespace views
125 128
126 #endif // UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_ 129 #endif // UI_VIEWS_ANIMATION_INK_DROP_RIPPLE_H_
OLDNEW
« no previous file with comments | « ui/views/animation/ink_drop_impl_unittest.cc ('k') | ui/views/animation/ink_drop_ripple.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698