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/heads_up_display_layer.h" | 5 #include "cc/heads_up_display_layer.h" |
6 #include "cc/layer.h" | 6 #include "cc/layer.h" |
7 #include "cc/layer_tree_host.h" | 7 #include "cc/layer_tree_host.h" |
8 #include "cc/test/layer_tree_test_common.h" | 8 #include "cc/test/layer_tree_test_common.h" |
9 | 9 |
10 using namespace WebKitTests; | 10 using namespace WebKitTests; |
11 | 11 |
12 namespace cc { | 12 namespace cc { |
13 namespace { | 13 namespace { |
14 | 14 |
15 class HeadsUpDisplayTest : public ThreadedTest { | 15 class HeadsUpDisplayTest : public ThreadedTest { |
16 protected: | 16 protected: |
17 virtual void initializeSettings(LayerTreeSettings& settings) OVERRIDE | 17 virtual void initializeSettings(LayerTreeSettings& settings) OVERRIDE |
18 { | 18 { |
19 // Enable the HUD without requiring text. | 19 // Enable the HUD without requiring text. |
20 settings.showPropertyChangedRects = true; | 20 settings.initialDebugState.showPropertyChangedRects = true; |
21 } | 21 } |
22 }; | 22 }; |
23 | 23 |
24 class DrawsContentLayer : public Layer { | 24 class DrawsContentLayer : public Layer { |
25 public: | 25 public: |
26 static scoped_refptr<DrawsContentLayer> create() { return make_scoped_refptr
(new DrawsContentLayer()); } | 26 static scoped_refptr<DrawsContentLayer> create() { return make_scoped_refptr
(new DrawsContentLayer()); } |
27 virtual bool drawsContent() const OVERRIDE { return true; } | 27 virtual bool drawsContent() const OVERRIDE { return true; } |
28 | 28 |
29 private: | 29 private: |
30 DrawsContentLayer() : Layer() { } | 30 DrawsContentLayer() : Layer() { } |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 int m_numCommits; | 103 int m_numCommits; |
104 }; | 104 }; |
105 | 105 |
106 TEST_F(HudWithRootLayerChange, runMultiThread) | 106 TEST_F(HudWithRootLayerChange, runMultiThread) |
107 { | 107 { |
108 runTest(true); | 108 runTest(true); |
109 } | 109 } |
110 | 110 |
111 } // namespace | 111 } // namespace |
112 } // namespace cc | 112 } // namespace cc |
OLD | NEW |