| Index: ui/views/test/platform_test_helper.cc
|
| diff --git a/ui/views/test/platform_test_helper.cc b/ui/views/test/platform_test_helper.cc
|
| index b6626189fa390b2141ef70e1ff3704344714770f..488a9e58fd36bd58e0ccdc38cef2fcebee57fbd6 100644
|
| --- a/ui/views/test/platform_test_helper.cc
|
| +++ b/ui/views/test/platform_test_helper.cc
|
| @@ -7,20 +7,15 @@
|
| #include "base/callback.h"
|
| #include "base/logging.h"
|
| #include "base/memory/ptr_util.h"
|
| +#include "ui/views/widget/widget.h"
|
| +
|
| +#if defined(USE_AURA)
|
| +#include "ui/aura/window.h"
|
| +#endif
|
|
|
| namespace views {
|
| namespace {
|
|
|
| -class DefaultPlatformTestHelper : public PlatformTestHelper {
|
| - public:
|
| - DefaultPlatformTestHelper() {}
|
| -
|
| - ~DefaultPlatformTestHelper() override {}
|
| -
|
| - private:
|
| - DISALLOW_COPY_AND_ASSIGN(DefaultPlatformTestHelper);
|
| -};
|
| -
|
| PlatformTestHelper::Factory test_helper_factory;
|
| bool is_mus = false;
|
| bool is_aura_mus_client = false;
|
| @@ -36,7 +31,7 @@ void PlatformTestHelper::set_factory(const Factory& factory) {
|
| std::unique_ptr<PlatformTestHelper> PlatformTestHelper::Create() {
|
| return !test_helper_factory.is_null()
|
| ? test_helper_factory.Run()
|
| - : base::WrapUnique(new DefaultPlatformTestHelper);
|
| + : base::WrapUnique(new PlatformTestHelper);
|
| }
|
|
|
| // static
|
| @@ -59,4 +54,10 @@ bool PlatformTestHelper::IsAuraMusClient() {
|
| return is_aura_mus_client;
|
| }
|
|
|
| +#if defined(USE_AURA)
|
| +void PlatformTestHelper::SimulateNativeDestroy(Widget* widget) {
|
| + delete widget->GetNativeView();
|
| +}
|
| +#endif
|
| +
|
| } // namespace views
|
|
|