| 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_TEST_LAYER_TREE_TEST_COMMON_H_ | 5 #ifndef CC_TEST_LAYER_TREE_TEST_COMMON_H_ |
| 6 #define CC_TEST_LAYER_TREE_TEST_COMMON_H_ | 6 #define CC_TEST_LAYER_TREE_TEST_COMMON_H_ |
| 7 | 7 |
| 8 #include "base/hash_tables.h" | 8 #include "base/hash_tables.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/threading/thread.h" | 10 #include "base/threading/thread.h" |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 void endTestAfterDelay(int delayMilliseconds); | 78 void endTestAfterDelay(int delayMilliseconds); |
| 79 | 79 |
| 80 void postSetNeedsAnimateToMainThread(); | 80 void postSetNeedsAnimateToMainThread(); |
| 81 void postAddAnimationToMainThread(cc::Layer*); | 81 void postAddAnimationToMainThread(cc::Layer*); |
| 82 void postAddInstantAnimationToMainThread(); | 82 void postAddInstantAnimationToMainThread(); |
| 83 void postSetNeedsCommitToMainThread(); | 83 void postSetNeedsCommitToMainThread(); |
| 84 void postAcquireLayerTextures(); | 84 void postAcquireLayerTextures(); |
| 85 void postSetNeedsRedrawToMainThread(); | 85 void postSetNeedsRedrawToMainThread(); |
| 86 void postSetNeedsAnimateAndCommitToMainThread(); | 86 void postSetNeedsAnimateAndCommitToMainThread(); |
| 87 void postSetVisibleToMainThread(bool visible); | 87 void postSetVisibleToMainThread(bool visible); |
| 88 void postDidAddAnimationToMainThread(); | |
| 89 | 88 |
| 90 void doBeginTest(); | 89 void doBeginTest(); |
| 91 void timeout(); | 90 void timeout(); |
| 92 | 91 |
| 93 cc::LayerTreeHost* layerTreeHost() { return m_layerTreeHost.get(); } | 92 cc::LayerTreeHost* layerTreeHost() { return m_layerTreeHost.get(); } |
| 94 | 93 |
| 95 protected: | 94 protected: |
| 96 ThreadedTest(); | 95 ThreadedTest(); |
| 97 | 96 |
| 98 virtual void initializeSettings(cc::LayerTreeSettings&) { } | 97 virtual void initializeSettings(cc::LayerTreeSettings&) { } |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 TEST_F(TEST_FIXTURE_NAME, runSingleThread) \ | 200 TEST_F(TEST_FIXTURE_NAME, runSingleThread) \ |
| 202 { \ | 201 { \ |
| 203 runTest(false); \ | 202 runTest(false); \ |
| 204 } \ | 203 } \ |
| 205 TEST_F(TEST_FIXTURE_NAME, runMultiThread) \ | 204 TEST_F(TEST_FIXTURE_NAME, runMultiThread) \ |
| 206 { \ | 205 { \ |
| 207 runTest(true); \ | 206 runTest(true); \ |
| 208 } | 207 } |
| 209 | 208 |
| 210 #endif // CC_TEST_LAYER_TREE_TEST_COMMON_H_ | 209 #endif // CC_TEST_LAYER_TREE_TEST_COMMON_H_ |
| OLD | NEW |