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

Side by Side Diff: cc/top_controls_manager.h

Issue 11967021: Remove top controls layer from cc/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove invalid TODO Created 7 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « cc/layer_tree_host.cc ('k') | cc/top_controls_manager.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CC_TOP_CONTROLS_MANAGER_H_ 5 #ifndef CC_TOP_CONTROLS_MANAGER_H_
6 #define CC_TOP_CONTROLS_MANAGER_H_ 6 #define CC_TOP_CONTROLS_MANAGER_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "cc/layer_impl.h" 10 #include "cc/layer_impl.h"
(...skipping 10 matching lines...) Expand all
21 class LayerTreeImpl; 21 class LayerTreeImpl;
22 class TopControlsManagerClient; 22 class TopControlsManagerClient;
23 23
24 // Manages the position of the top controls. 24 // Manages the position of the top controls.
25 class CC_EXPORT TopControlsManager { 25 class CC_EXPORT TopControlsManager {
26 public: 26 public:
27 static scoped_ptr<TopControlsManager> Create(TopControlsManagerClient* client, 27 static scoped_ptr<TopControlsManager> Create(TopControlsManagerClient* client,
28 float top_controls_height); 28 float top_controls_height);
29 virtual ~TopControlsManager(); 29 virtual ~TopControlsManager();
30 30
31 void set_content_layer_id(int id) { content_layer_id_ = id; }
32 float controls_top_offset() { return controls_top_offset_; } 31 float controls_top_offset() { return controls_top_offset_; }
33 float content_top_offset() { return content_top_offset_; } 32 float content_top_offset() { return content_top_offset_; }
34 float is_overlay_mode() { return is_overlay_mode_; } 33 float is_overlay_mode() { return is_overlay_mode_; }
35 KeyframedFloatAnimationCurve* animation() { 34 KeyframedFloatAnimationCurve* animation() {
36 return top_controls_animation_.get(); 35 return top_controls_animation_.get();
37 } 36 }
38 37
39 void UpdateDrawPositions(); 38 void UpdateDrawPositions();
40 39
41 void ScrollBegin(); 40 void ScrollBegin();
(...skipping 11 matching lines...) Expand all
53 void ResetAnimations(); 52 void ResetAnimations();
54 LayerImpl* RootScrollLayer(); 53 LayerImpl* RootScrollLayer();
55 float RootScrollLayerTotalScrollY(); 54 float RootScrollLayerTotalScrollY();
56 void SetupAnimation(bool show_controls); 55 void SetupAnimation(bool show_controls);
57 void StartAnimationIfNecessary(); 56 void StartAnimationIfNecessary();
58 57
59 TopControlsManagerClient* client_; // The client manages the lifecycle of 58 TopControlsManagerClient* client_; // The client manages the lifecycle of
60 // this. 59 // this.
61 60
62 scoped_ptr<KeyframedFloatAnimationCurve> top_controls_animation_; 61 scoped_ptr<KeyframedFloatAnimationCurve> top_controls_animation_;
63 int content_layer_id_;
64 bool is_showing_animation_; 62 bool is_showing_animation_;
65 bool is_overlay_mode_; 63 bool is_overlay_mode_;
66 float controls_top_offset_; 64 float controls_top_offset_;
67 float content_top_offset_; 65 float content_top_offset_;
68 float top_controls_height_; 66 float top_controls_height_;
69 bool scroll_readjustment_enabled_; 67 bool scroll_readjustment_enabled_;
70 float previous_root_scroll_offset_; 68 float previous_root_scroll_offset_;
71 69
72 DISALLOW_COPY_AND_ASSIGN(TopControlsManager); 70 DISALLOW_COPY_AND_ASSIGN(TopControlsManager);
73 }; 71 };
74 72
75 } // namespace cc 73 } // namespace cc
76 74
77 #endif // CC_TOP_CONTROLS_MANAGER_H_ 75 #endif // CC_TOP_CONTROLS_MANAGER_H_
OLDNEW
« no previous file with comments | « cc/layer_tree_host.cc ('k') | cc/top_controls_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698