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

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

Issue 1937103003: Rename of InkDropAnimation classes to InkDropRipple. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed test_ink_drop_animation_observer.h from views.gyp and doc update. Created 4 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 unified diff | Download patch
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_HOST_H_ 5 #ifndef UI_VIEWS_ANIMATION_INK_DROP_HOST_H_
6 #define UI_VIEWS_ANIMATION_INK_DROP_HOST_H_ 6 #define UI_VIEWS_ANIMATION_INK_DROP_HOST_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "ui/gfx/geometry/point.h" 11 #include "ui/gfx/geometry/point.h"
12 #include "ui/views/views_export.h" 12 #include "ui/views/views_export.h"
13 13
14 namespace ui { 14 namespace ui {
15 class Layer; 15 class Layer;
16 } // namespace ui 16 } // namespace ui
17 17
18 namespace views { 18 namespace views {
19 19
20 class InkDropAnimation; 20 class InkDropRipple;
21 class InkDropHover; 21 class InkDropHover;
22 22
23 // Used by the InkDropAnimationController to add and remove the ink drop layers 23 // Used by the InkDropAnimationController to add and remove the ink drop layers
24 // from a host's layer tree. Typically the ink drop layer is added to a View's 24 // from a host's layer tree. Typically the ink drop layer is added to a View's
25 // layer but it can also be added to a View's ancestor layer. 25 // layer but it can also be added to a View's ancestor layer.
26 // 26 //
27 // Note: Some Views do not own a Layer, but you can use 27 // Note: Some Views do not own a Layer, but you can use
28 // View::SetLayer(new ui::Layer(ui::LAYER_NOT_DRAWN)) to force the View to have 28 // View::SetLayer(new ui::Layer(ui::LAYER_NOT_DRAWN)) to force the View to have
29 // a lightweight Layer that can parent the ink drop layer. 29 // a lightweight Layer that can parent the ink drop layer.
30 class VIEWS_EXPORT InkDropHost { 30 class VIEWS_EXPORT InkDropHost {
31 public: 31 public:
32 InkDropHost() {} 32 InkDropHost() {}
33 virtual ~InkDropHost() {} 33 virtual ~InkDropHost() {}
34 34
35 // Adds the |ink_drop_layer| in to a visible layer tree. 35 // Adds the |ink_drop_layer| in to a visible layer tree.
36 virtual void AddInkDropLayer(ui::Layer* ink_drop_layer) = 0; 36 virtual void AddInkDropLayer(ui::Layer* ink_drop_layer) = 0;
37 37
38 // Removes |ink_drop_layer| from the layer tree. 38 // Removes |ink_drop_layer| from the layer tree.
39 virtual void RemoveInkDropLayer(ui::Layer* ink_drop_layer) = 0; 39 virtual void RemoveInkDropLayer(ui::Layer* ink_drop_layer) = 0;
40 40
41 // Creates and returns the effect used for press. 41 // Creates and returns the effect used for press.
42 virtual std::unique_ptr<InkDropAnimation> CreateInkDropAnimation() const = 0; 42 virtual std::unique_ptr<InkDropRipple> CreateInkDropRipple() const = 0;
43 43
44 // Creates and returns the effect used for hover. 44 // Creates and returns the effect used for hover.
45 virtual std::unique_ptr<InkDropHover> CreateInkDropHover() const = 0; 45 virtual std::unique_ptr<InkDropHover> CreateInkDropHover() const = 0;
46 46
47 private: 47 private:
48 DISALLOW_COPY_AND_ASSIGN(InkDropHost); 48 DISALLOW_COPY_AND_ASSIGN(InkDropHost);
49 }; 49 };
50 50
51 } // namespace views 51 } // namespace views
52 52
53 #endif // UI_VIEWS_ANIMATION_INK_DROP_HOST_H_ 53 #endif // UI_VIEWS_ANIMATION_INK_DROP_HOST_H_
OLDNEW
« no previous file with comments | « ui/views/animation/ink_drop_animation_unittest.cc ('k') | ui/views/animation/ink_drop_host_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698