Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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_TREES_LAYER_TREE_HOST_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_H_ |
| 6 #define CC_TREES_LAYER_TREE_HOST_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_H_ |
| 7 | 7 |
| 8 #include <limits> | 8 #include <limits> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 231 std::numeric_limits<size_t>::max(); | 231 std::numeric_limits<size_t>::max(); |
| 232 } | 232 } |
| 233 bool RequestPartialTextureUpdate(); | 233 bool RequestPartialTextureUpdate(); |
| 234 | 234 |
| 235 void SetDeviceScaleFactor(float device_scale_factor); | 235 void SetDeviceScaleFactor(float device_scale_factor); |
| 236 float device_scale_factor() const { return device_scale_factor_; } | 236 float device_scale_factor() const { return device_scale_factor_; } |
| 237 | 237 |
| 238 void UpdateTopControlsState(TopControlsState constraints, | 238 void UpdateTopControlsState(TopControlsState constraints, |
| 239 TopControlsState current, | 239 TopControlsState current, |
| 240 bool animate); | 240 bool animate); |
| 241 void UpdateTopControlsStatePreservingConstraints(bool show); | |
|
aelias_OOO_until_Jul13
2013/06/10 05:11:25
Please change the arguments here to "TopControlsSt
Jinsuk Kim
2013/06/10 05:37:09
Done.
| |
| 241 | 242 |
| 242 HeadsUpDisplayLayer* hud_layer() const { return hud_layer_.get(); } | 243 HeadsUpDisplayLayer* hud_layer() const { return hud_layer_.get(); } |
| 243 | 244 |
| 244 Proxy* proxy() const { return proxy_.get(); } | 245 Proxy* proxy() const { return proxy_.get(); } |
| 245 | 246 |
| 246 AnimationRegistrar* animation_registrar() const { | 247 AnimationRegistrar* animation_registrar() const { |
| 247 return animation_registrar_.get(); | 248 return animation_registrar_.get(); |
| 248 } | 249 } |
| 249 | 250 |
| 250 skia::RefPtr<SkPicture> CapturePicture(); | 251 skia::RefPtr<SkPicture> CapturePicture(); |
| 251 | 252 |
| 252 bool BlocksPendingCommit() const; | 253 bool BlocksPendingCommit() const; |
| 253 | 254 |
| 254 // Obtains a thorough dump of the LayerTreeHost as a value. | 255 // Obtains a thorough dump of the LayerTreeHost as a value. |
| 255 scoped_ptr<base::Value> AsValue() const; | 256 scoped_ptr<base::Value> AsValue() const; |
| 256 | 257 |
| 257 bool in_paint_layer_contents() const { return in_paint_layer_contents_; } | 258 bool in_paint_layer_contents() const { return in_paint_layer_contents_; } |
| 258 | 259 |
| 260 | |
|
aelias_OOO_until_Jul13
2013/06/10 05:11:25
Nit: extra newline
Jinsuk Kim
2013/06/10 05:37:09
Done.
| |
| 259 void IncrementLCDTextMetrics( | 261 void IncrementLCDTextMetrics( |
| 260 bool update_total_num_cc_layers_can_use_lcd_text, | 262 bool update_total_num_cc_layers_can_use_lcd_text, |
| 261 bool update_total_num_cc_layers_will_use_lcd_text); | 263 bool update_total_num_cc_layers_will_use_lcd_text); |
| 262 | 264 |
| 263 protected: | 265 protected: |
| 264 LayerTreeHost(LayerTreeHostClient* client, const LayerTreeSettings& settings); | 266 LayerTreeHost(LayerTreeHostClient* client, const LayerTreeSettings& settings); |
| 265 bool Initialize(scoped_ptr<Thread> impl_thread); | 267 bool Initialize(scoped_ptr<Thread> impl_thread); |
| 266 bool InitializeForTesting(scoped_ptr<Proxy> proxy_for_testing); | 268 bool InitializeForTesting(scoped_ptr<Proxy> proxy_for_testing); |
| 267 | 269 |
| 268 private: | 270 private: |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 359 : total_num_cc_layers(0), | 361 : total_num_cc_layers(0), |
| 360 total_num_cc_layers_can_use_lcd_text(0), | 362 total_num_cc_layers_can_use_lcd_text(0), |
| 361 total_num_cc_layers_will_use_lcd_text(0) {} | 363 total_num_cc_layers_will_use_lcd_text(0) {} |
| 362 | 364 |
| 363 int64 total_num_cc_layers; | 365 int64 total_num_cc_layers; |
| 364 int64 total_num_cc_layers_can_use_lcd_text; | 366 int64 total_num_cc_layers_can_use_lcd_text; |
| 365 int64 total_num_cc_layers_will_use_lcd_text; | 367 int64 total_num_cc_layers_will_use_lcd_text; |
| 366 }; | 368 }; |
| 367 LCDTextMetrics lcd_text_metrics_; | 369 LCDTextMetrics lcd_text_metrics_; |
| 368 | 370 |
| 371 TopControlsState top_controls_constraints_; | |
| 372 TopControlsState GetTopControlsConstraints() const { | |
|
aelias_OOO_until_Jul13
2013/06/10 05:11:25
No need for this private getter, please delete it.
Jinsuk Kim
2013/06/10 05:37:09
Done.
| |
| 373 return top_controls_constraints_; | |
| 374 } | |
| 375 | |
| 369 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 376 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
| 370 }; | 377 }; |
| 371 | 378 |
| 372 } // namespace cc | 379 } // namespace cc |
| 373 | 380 |
| 374 #endif // CC_TREES_LAYER_TREE_HOST_H_ | 381 #endif // CC_TREES_LAYER_TREE_HOST_H_ |
| OLD | NEW |