Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(734)

Unified Diff: ui/views/examples/content_client/examples_browser_main_parts.cc

Issue 191723003: Nukes USE_AURA ifdefs from views (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cleanup Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/views/examples/content_client/examples_browser_main_parts.cc
diff --git a/ui/views/examples/content_client/examples_browser_main_parts.cc b/ui/views/examples/content_client/examples_browser_main_parts.cc
index fadf23e4b8dd3796f4b11da6af4261f26f820b0d..2b4fd6b63b4f28ee1ef3a6bac071124400dacce3 100644
--- a/ui/views/examples/content_client/examples_browser_main_parts.cc
+++ b/ui/views/examples/content_client/examples_browser_main_parts.cc
@@ -13,18 +13,15 @@
#include "base/threading/thread_restrictions.h"
#include "content/public/common/content_switches.h"
#include "content/shell/browser/shell_browser_context.h"
-#include "ui/base/ime/input_method_initializer.h"
-#include "ui/views/examples/examples_window_with_content.h"
-#include "ui/views/test/desktop_test_views_delegate.h"
-#include "url/gurl.h"
-
-#if defined(USE_AURA)
#include "ui/aura/env.h"
+#include "ui/base/ime/input_method_initializer.h"
#include "ui/gfx/screen.h"
#include "ui/views/corewm/wm_state.h"
+#include "ui/views/examples/examples_window_with_content.h"
+#include "ui/views/test/desktop_test_views_delegate.h"
#include "ui/views/widget/desktop_aura/desktop_screen.h"
#include "ui/views/widget/native_widget_aura.h"
-#endif
+#include "url/gurl.h"
#if defined(OS_CHROMEOS)
#include "ui/aura/test/test_screen.h"
@@ -44,9 +41,7 @@ ExamplesBrowserMainParts::~ExamplesBrowserMainParts() {
}
void ExamplesBrowserMainParts::ToolkitInitialized() {
-#if defined(USE_AURA)
wm_state_.reset(new views::corewm::WMState);
-#endif
}
void ExamplesBrowserMainParts::PreMainMessageLoopRun() {
@@ -63,7 +58,7 @@ void ExamplesBrowserMainParts::PreMainMessageLoopRun() {
wm_test_helper_->host()->Show();
// Ensure Aura knows where to open new windows.
window_context = wm_test_helper_->host()->window();
-#elif defined(USE_AURA)
+#else
aura::Env::CreateInstance();
gfx::Screen::SetScreenInstance(
gfx::SCREEN_TYPE_NATIVE, CreateDesktopScreen());
@@ -80,9 +75,7 @@ void ExamplesBrowserMainParts::PostMainMessageLoopRun() {
wm_test_helper_.reset();
#endif
views_delegate_.reset();
-#if defined(USE_AURA)
aura::Env::DeleteInstance();
-#endif
}
bool ExamplesBrowserMainParts::MainMessageLoopRun(int* result_code) {

Powered by Google App Engine
This is Rietveld 408576698