| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "ui/views/test/views_test_base.h" | 5 #include "ui/views/test/views_test_base.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/environment.h" | 9 #include "base/environment.h" |
| 10 #include "base/run_loop.h" | 10 #include "base/run_loop.h" |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 run_loop.RunUntilIdle(); | 99 run_loop.RunUntilIdle(); |
| 100 } | 100 } |
| 101 | 101 |
| 102 Widget::InitParams ViewsTestBase::CreateParams( | 102 Widget::InitParams ViewsTestBase::CreateParams( |
| 103 Widget::InitParams::Type type) { | 103 Widget::InitParams::Type type) { |
| 104 Widget::InitParams params(type); | 104 Widget::InitParams params(type); |
| 105 params.context = GetContext(); | 105 params.context = GetContext(); |
| 106 return params; | 106 return params; |
| 107 } | 107 } |
| 108 | 108 |
| 109 bool ViewsTestBase::HasCompositingManager() const { |
| 110 return has_compositing_manager_; |
| 111 } |
| 112 |
| 113 void ViewsTestBase::SimulateNativeDestroy(Widget* widget) { |
| 114 test_helper_->platform_test_helper()->SimulateNativeDestroy(widget); |
| 115 } |
| 116 |
| 109 gfx::NativeWindow ViewsTestBase::GetContext() { | 117 gfx::NativeWindow ViewsTestBase::GetContext() { |
| 110 return test_helper_->GetContext(); | 118 return test_helper_->GetContext(); |
| 111 } | 119 } |
| 112 | 120 |
| 113 bool ViewsTestBase::HasCompositingManager() const { | |
| 114 return has_compositing_manager_; | |
| 115 } | |
| 116 | |
| 117 } // namespace views | 121 } // namespace views |
| OLD | NEW |