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

Side by Side Diff: cc/layers/scrollbar_layer_impl.h

Issue 23102003: Note scrollbar layer properties changed when position changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | cc/layers/scrollbar_layer_impl.cc » ('j') | cc/layers/scrollbar_layer_impl.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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_LAYERS_SCROLLBAR_LAYER_IMPL_H_ 5 #ifndef CC_LAYERS_SCROLLBAR_LAYER_IMPL_H_
6 #define CC_LAYERS_SCROLLBAR_LAYER_IMPL_H_ 6 #define CC_LAYERS_SCROLLBAR_LAYER_IMPL_H_
7 7
8 #include "cc/base/cc_export.h" 8 #include "cc/base/cc_export.h"
9 #include "cc/input/scrollbar.h" 9 #include "cc/input/scrollbar.h"
10 #include "cc/layers/layer_impl.h" 10 #include "cc/layers/layer_impl.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 thumb_resource_id_ = id; 65 thumb_resource_id_ = id;
66 } 66 }
67 void set_visible_to_total_length_ratio(float ratio) { 67 void set_visible_to_total_length_ratio(float ratio) {
68 visible_to_total_length_ratio_ = ratio; 68 visible_to_total_length_ratio_ = ratio;
69 } 69 }
70 void set_is_overlay_scrollbar(bool is_overlay_scrollbar) { 70 void set_is_overlay_scrollbar(bool is_overlay_scrollbar) {
71 is_overlay_scrollbar_ = is_overlay_scrollbar; 71 is_overlay_scrollbar_ = is_overlay_scrollbar;
72 } 72 }
73 bool is_overlay_scrollbar() const { return is_overlay_scrollbar_; } 73 bool is_overlay_scrollbar() const { return is_overlay_scrollbar_; }
74 74
75 void SetCurrentPos(float current_pos) { current_pos_ = current_pos; } 75 void SetCurrentPos(float current_pos);
76 void SetMaximum(int maximum) { maximum_ = maximum; } 76 void SetMaximum(int maximum);
77 77
78 gfx::Rect ComputeThumbQuadRect() const; 78 gfx::Rect ComputeThumbQuadRect() const;
79 79
80 protected: 80 protected:
81 ScrollbarLayerImpl(LayerTreeImpl* tree_impl, 81 ScrollbarLayerImpl(LayerTreeImpl* tree_impl,
82 int id, 82 int id,
83 ScrollbarOrientation orientation); 83 ScrollbarOrientation orientation);
84 84
85 private: 85 private:
86 virtual const char* LayerTypeAsString() const OVERRIDE; 86 virtual const char* LayerTypeAsString() const OVERRIDE;
(...skipping 19 matching lines...) Expand all
106 106
107 int scroll_layer_id_; 107 int scroll_layer_id_;
108 108
109 bool is_overlay_scrollbar_; 109 bool is_overlay_scrollbar_;
110 110
111 DISALLOW_COPY_AND_ASSIGN(ScrollbarLayerImpl); 111 DISALLOW_COPY_AND_ASSIGN(ScrollbarLayerImpl);
112 }; 112 };
113 113
114 } // namespace cc 114 } // namespace cc
115 #endif // CC_LAYERS_SCROLLBAR_LAYER_IMPL_H_ 115 #endif // CC_LAYERS_SCROLLBAR_LAYER_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | cc/layers/scrollbar_layer_impl.cc » ('j') | cc/layers/scrollbar_layer_impl.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698