| OLD | NEW |
| 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 #include "cc/layers/scrollbar_layer.h" | 5 #include "cc/layers/scrollbar_layer.h" |
| 6 | 6 |
| 7 #include "cc/animation/scrollbar_animation_controller.h" | 7 #include "cc/animation/scrollbar_animation_controller.h" |
| 8 #include "cc/layers/append_quads_data.h" | 8 #include "cc/layers/append_quads_data.h" |
| 9 #include "cc/layers/scrollbar_layer_impl.h" | 9 #include "cc/layers/scrollbar_layer_impl.h" |
| 10 #include "cc/quads/solid_color_draw_quad.h" | 10 #include "cc/quads/solid_color_draw_quad.h" |
| 11 #include "cc/resources/prioritized_resource_manager.h" | 11 #include "cc/resources/prioritized_resource_manager.h" |
| 12 #include "cc/resources/priority_calculator.h" | 12 #include "cc/resources/priority_calculator.h" |
| 13 #include "cc/resources/resource_update_queue.h" | 13 #include "cc/resources/resource_update_queue.h" |
| 14 #include "cc/test/fake_impl_proxy.h" | 14 #include "cc/test/fake_impl_proxy.h" |
| 15 #include "cc/test/fake_layer_tree_host_client.h" | 15 #include "cc/test/fake_layer_tree_host_client.h" |
| 16 #include "cc/test/fake_layer_tree_host_impl.h" | 16 #include "cc/test/fake_layer_tree_host_impl.h" |
| 17 #include "cc/test/fake_scrollbar_theme_painter.h" | 17 #include "cc/test/fake_scrollbar_theme_painter.h" |
| 18 #include "cc/test/fake_web_scrollbar.h" | 18 #include "cc/test/fake_web_scrollbar.h" |
| 19 #include "cc/test/fake_web_scrollbar_theme_geometry.h" | 19 #include "cc/test/fake_web_scrollbar_theme_geometry.h" |
| 20 #include "cc/test/geometry_test_utils.h" | 20 #include "cc/test/geometry_test_utils.h" |
| 21 #include "cc/test/layer_tree_test.h" | 21 #include "cc/test/layer_tree_test.h" |
| 22 #include "cc/test/mock_quad_culler.h" | 22 #include "cc/test/mock_quad_culler.h" |
| 23 #include "cc/test/test_web_graphics_context_3d.h" | 23 #include "cc/test/test_web_graphics_context_3d.h" |
| 24 #include "cc/trees/layer_tree_impl.h" | 24 #include "cc/trees/layer_tree_impl.h" |
| 25 #include "cc/trees/single_thread_proxy.h" | 25 #include "cc/trees/single_thread_proxy.h" |
| 26 #include "cc/trees/tree_synchronizer.h" | 26 #include "cc/trees/tree_synchronizer.h" |
| 27 #include "testing/gmock/include/gmock/gmock.h" | 27 #include "testing/gmock/include/gmock/gmock.h" |
| 28 #include "testing/gtest/include/gtest/gtest.h" | 28 #include "testing/gtest/include/gtest/gtest.h" |
| 29 #include "third_party/WebKit/Source/Platform/chromium/public/WebScrollbar.h" | 29 #include "third_party/WebKit/public/platform/WebScrollbar.h" |
| 30 #include "third_party/WebKit/Source/Platform/chromium/public/WebScrollbarThemeGe
ometry.h" | 30 #include "third_party/WebKit/public/platform/WebScrollbarThemeGeometry.h" |
| 31 | 31 |
| 32 namespace cc { | 32 namespace cc { |
| 33 namespace { | 33 namespace { |
| 34 | 34 |
| 35 scoped_ptr<LayerImpl> LayerImplForScrollAreaAndScrollbar( | 35 scoped_ptr<LayerImpl> LayerImplForScrollAreaAndScrollbar( |
| 36 FakeLayerTreeHostImpl* host_impl, | 36 FakeLayerTreeHostImpl* host_impl, |
| 37 scoped_ptr<WebKit::WebScrollbar> scrollbar, | 37 scoped_ptr<WebKit::WebScrollbar> scrollbar, |
| 38 bool reverse_order) { | 38 bool reverse_order) { |
| 39 scoped_refptr<Layer> layer_tree_root = Layer::Create(); | 39 scoped_refptr<Layer> layer_tree_root = Layer::Create(); |
| 40 scoped_refptr<Layer> child1 = Layer::Create(); | 40 scoped_refptr<Layer> child1 = Layer::Create(); |
| (...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 421 TestResourceUpload(2); | 421 TestResourceUpload(2); |
| 422 } | 422 } |
| 423 | 423 |
| 424 TEST_F(ScrollbarLayerTestResourceCreation, SolidColorNoResourceUpload) { | 424 TEST_F(ScrollbarLayerTestResourceCreation, SolidColorNoResourceUpload) { |
| 425 layer_tree_settings_.solid_color_scrollbars = true; | 425 layer_tree_settings_.solid_color_scrollbars = true; |
| 426 TestResourceUpload(0); | 426 TestResourceUpload(0); |
| 427 } | 427 } |
| 428 | 428 |
| 429 } // namespace | 429 } // namespace |
| 430 } // namespace cc | 430 } // namespace cc |
| OLD | NEW |