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

Unified Diff: athena/main/athena_main.cc

Issue 412713002: Move apps/shell to extensions/shell. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 40% Created 6 years, 5 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
« no previous file with comments | « athena/main/athena_app_window_controller.cc ('k') | athena/main/athena_main.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: athena/main/athena_main.cc
diff --git a/athena/main/athena_main.cc b/athena/main/athena_main.cc
index 628603427b79476c0aa4eff44267e3310dd48b7c..d50330e237bed0f1bf118af7868ccc9051f40e27 100644
--- a/athena/main/athena_main.cc
+++ b/athena/main/athena_main.cc
@@ -2,13 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "apps/shell/app/shell_main_delegate.h"
-#include "apps/shell/browser/shell_browser_main_delegate.h"
-#include "apps/shell/browser/shell_content_browser_client.h"
-#include "apps/shell/browser/shell_desktop_controller.h"
-#include "apps/shell/browser/shell_extension_system.h"
-#include "apps/shell/common/switches.h"
-#include "apps/shell/renderer/shell_renderer_main_delegate.h"
#include "athena/content/public/content_activity_factory.h"
#include "athena/content/public/content_app_model_builder.h"
#include "athena/home/public/home_card.h"
@@ -24,6 +17,13 @@
#include "base/file_util.h"
#include "base/path_service.h"
#include "content/public/app/content_main.h"
+#include "extensions/shell/app/shell_main_delegate.h"
+#include "extensions/shell/browser/shell_browser_main_delegate.h"
+#include "extensions/shell/browser/shell_content_browser_client.h"
+#include "extensions/shell/browser/shell_desktop_controller.h"
+#include "extensions/shell/browser/shell_extension_system.h"
+#include "extensions/shell/common/switches.h"
+#include "extensions/shell/renderer/shell_renderer_main_delegate.h"
#include "ui/app_list/app_list_switches.h"
#include "ui/aura/window_tree_host.h"
#include "ui/base/resource/resource_bundle.h"
@@ -60,13 +60,13 @@ class VirtualKeyboardObserver : public keyboard::KeyboardControllerObserver {
DISALLOW_COPY_AND_ASSIGN(VirtualKeyboardObserver);
};
-class AthenaDesktopController : public apps::ShellDesktopController {
+class AthenaDesktopController : public extensions::ShellDesktopController {
public:
AthenaDesktopController() {}
virtual ~AthenaDesktopController() {}
private:
- // apps::ShellDesktopController:
+ // extensions::ShellDesktopController:
virtual wm::FocusRules* CreateFocusRules() OVERRIDE {
return athena::ScreenManager::CreateFocusRules();
}
@@ -74,12 +74,12 @@ class AthenaDesktopController : public apps::ShellDesktopController {
DISALLOW_COPY_AND_ASSIGN(AthenaDesktopController);
};
-class AthenaBrowserMainDelegate : public apps::ShellBrowserMainDelegate {
+class AthenaBrowserMainDelegate : public extensions::ShellBrowserMainDelegate {
public:
AthenaBrowserMainDelegate() {}
virtual ~AthenaBrowserMainDelegate() {}
- // apps::ShellBrowserMainDelegate:
+ // extensions::ShellBrowserMainDelegate:
virtual void Start(content::BrowserContext* context) OVERRIDE {
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
@@ -87,9 +87,10 @@ class AthenaBrowserMainDelegate : public apps::ShellBrowserMainDelegate {
command_line->AppendSwitch(app_list::switches::kEnableExperimentalAppList);
base::FilePath app_dir = base::FilePath::FromUTF8Unsafe(
- command_line->HasSwitch(apps::switches::kAppShellAppPath) ?
- command_line->GetSwitchValueNative(apps::switches::kAppShellAppPath) :
- kDefaultAppPath);
+ command_line->HasSwitch(extensions::switches::kAppShellAppPath)
+ ? command_line->GetSwitchValueNative(
+ extensions::switches::kAppShellAppPath)
+ : kDefaultAppPath);
base::FilePath app_absolute_dir = base::MakeAbsoluteFilePath(app_dir);
if (base::DirectoryExists(app_absolute_dir)) {
@@ -100,7 +101,7 @@ class AthenaBrowserMainDelegate : public apps::ShellBrowserMainDelegate {
}
athena::StartAthena(
- apps::ShellDesktopController::instance()->host()->window(),
+ extensions::ShellDesktopController::instance()->host()->window(),
new athena::ContentActivityFactory(),
new athena::ContentAppModelBuilder(context));
athena::HomeCard::Get()->RegisterSearchProvider(
@@ -117,10 +118,11 @@ class AthenaBrowserMainDelegate : public apps::ShellBrowserMainDelegate {
athena::ShutdownAthena();
}
- virtual apps::ShellDesktopController* CreateDesktopController() OVERRIDE {
+ virtual extensions::ShellDesktopController* CreateDesktopController()
+ OVERRIDE {
// TODO(mukai): create Athena's own ShellDesktopController subclass so that
// it can initialize its own window manager logic.
- apps::ShellDesktopController* desktop = new AthenaDesktopController();
+ extensions::ShellDesktopController* desktop = new AthenaDesktopController();
desktop->SetAppWindowController(new athena::AthenaAppWindowController());
return desktop;
}
@@ -131,10 +133,12 @@ class AthenaBrowserMainDelegate : public apps::ShellBrowserMainDelegate {
DISALLOW_COPY_AND_ASSIGN(AthenaBrowserMainDelegate);
};
-class AthenaContentBrowserClient : public apps::ShellContentBrowserClient {
+class AthenaContentBrowserClient
+ : public extensions::ShellContentBrowserClient {
public:
AthenaContentBrowserClient()
- : apps::ShellContentBrowserClient(new AthenaBrowserMainDelegate()) {}
+ : extensions::ShellContentBrowserClient(new AthenaBrowserMainDelegate()) {
+ }
virtual ~AthenaContentBrowserClient() {}
// content::ContentBrowserClient:
@@ -148,13 +152,14 @@ class AthenaContentBrowserClient : public apps::ShellContentBrowserClient {
DISALLOW_COPY_AND_ASSIGN(AthenaContentBrowserClient);
};
-class AthenaRendererMainDelegate : public apps::ShellRendererMainDelegate {
+class AthenaRendererMainDelegate
+ : public extensions::ShellRendererMainDelegate {
public:
AthenaRendererMainDelegate() {}
virtual ~AthenaRendererMainDelegate() {}
private:
- // apps::ShellRendererMainDelegate:
+ // extensions::ShellRendererMainDelegate:
virtual void OnThreadStarted(content::RenderThread* thread) OVERRIDE {}
virtual void OnViewCreated(content::RenderView* render_view) OVERRIDE {
@@ -164,21 +169,21 @@ class AthenaRendererMainDelegate : public apps::ShellRendererMainDelegate {
DISALLOW_COPY_AND_ASSIGN(AthenaRendererMainDelegate);
};
-class AthenaMainDelegate : public apps::ShellMainDelegate {
+class AthenaMainDelegate : public extensions::ShellMainDelegate {
public:
AthenaMainDelegate() {}
virtual ~AthenaMainDelegate() {}
private:
- // apps::ShellMainDelegate:
+ // extensions::ShellMainDelegate:
virtual content::ContentBrowserClient* CreateShellContentBrowserClient()
OVERRIDE {
return new AthenaContentBrowserClient();
}
- virtual scoped_ptr<apps::ShellRendererMainDelegate>
+ virtual scoped_ptr<extensions::ShellRendererMainDelegate>
CreateShellRendererMainDelegate() OVERRIDE {
- return scoped_ptr<apps::ShellRendererMainDelegate>(
+ return scoped_ptr<extensions::ShellRendererMainDelegate>(
new AthenaRendererMainDelegate());
}
« no previous file with comments | « athena/main/athena_app_window_controller.cc ('k') | athena/main/athena_main.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698