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

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

Issue 2125223004: Restore focus-state ink drop highlight on buttons after ripple animation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: IWYU Created 4 years, 4 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 | « no previous file | ui/views/animation/ink_drop_impl.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_IMPL_H_ 5 #ifndef UI_VIEWS_ANIMATION_INK_DROP_IMPL_H_
6 #define UI_VIEWS_ANIMATION_INK_DROP_IMPL_H_ 6 #define UI_VIEWS_ANIMATION_INK_DROP_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 bool explode); 100 bool explode);
101 101
102 // Returns true if this ink drop is hovered or focused. 102 // Returns true if this ink drop is hovered or focused.
103 bool ShouldHighlight() const; 103 bool ShouldHighlight() const;
104 104
105 // Starts the |highlight_after_ripple_timer_| timer. This will stop the 105 // Starts the |highlight_after_ripple_timer_| timer. This will stop the
106 // current 106 // current
107 // |highlight_after_ripple_timer_| instance if it exists. 107 // |highlight_after_ripple_timer_| instance if it exists.
108 void StartHighlightAfterRippleTimer(); 108 void StartHighlightAfterRippleTimer();
109 109
110 // Stops and destroys the current |highlight_after_ripple_timer_| instance.
111 void StopHighlightAfterRippleTimer();
112
113 // Callback for when the |highlight_after_ripple_timer_| fires. 110 // Callback for when the |highlight_after_ripple_timer_| fires.
114 void HighlightAfterRippleTimerFired(); 111 void HighlightAfterRippleTimerFired();
115 112
116 // The host of the ink drop. Used to poll for information such as whether the 113 // The host of the ink drop. Used to poll for information such as whether the
117 // highlight should be shown or not. 114 // highlight should be shown or not.
118 InkDropHost* ink_drop_host_; 115 InkDropHost* ink_drop_host_;
119 116
120 // The root Layer that parents the InkDropRipple layers and the 117 // The root Layer that parents the InkDropRipple layers and the
121 // InkDropHighlight layers. The |root_layer_| is the one that is added and 118 // InkDropHighlight layers. The |root_layer_| is the one that is added and
122 // removed from the InkDropHost. 119 // removed from the InkDropHost.
(...skipping 20 matching lines...) Expand all
143 // The timer used to delay the highlight fade in after an ink drop ripple 140 // The timer used to delay the highlight fade in after an ink drop ripple
144 // animation. 141 // animation.
145 std::unique_ptr<base::Timer> highlight_after_ripple_timer_; 142 std::unique_ptr<base::Timer> highlight_after_ripple_timer_;
146 143
147 DISALLOW_COPY_AND_ASSIGN(InkDropImpl); 144 DISALLOW_COPY_AND_ASSIGN(InkDropImpl);
148 }; 145 };
149 146
150 } // namespace views 147 } // namespace views
151 148
152 #endif // UI_VIEWS_ANIMATION_INK_DROP_IMPL_H_ 149 #endif // UI_VIEWS_ANIMATION_INK_DROP_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | ui/views/animation/ink_drop_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698