summaryrefslogtreecommitdiffstats
path: root/ash/shell
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-05-30 18:21:06 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-05-30 18:21:06 +0000
commitbe561d9aad6d51a27607e956db95fc5211364d1d (patch)
tree80dd2361d182a055528f1756c0768e617aa5e44f /ash/shell
parent50f50dc892b62a731a98c6b44cec0a9391d3c4d2 (diff)
downloadchromium_src-be561d9aad6d51a27607e956db95fc5211364d1d.zip
chromium_src-be561d9aad6d51a27607e956db95fc5211364d1d.tar.gz
chromium_src-be561d9aad6d51a27607e956db95fc5211364d1d.tar.bz2
Give ContentMainDelegate a default implementation to simplify embedders.
BUG=98716 Review URL: https://chromiumcodereview.appspot.com/10458034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139582 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/shell')
-rw-r--r--ash/shell/content_client/shell_main_delegate.cc34
-rw-r--r--ash/shell/content_client/shell_main_delegate.h14
2 files changed, 1 insertions, 47 deletions
diff --git a/ash/shell/content_client/shell_main_delegate.cc b/ash/shell/content_client/shell_main_delegate.cc
index 143de66..3257ae2 100644
--- a/ash/shell/content_client/shell_main_delegate.cc
+++ b/ash/shell/content_client/shell_main_delegate.cc
@@ -8,7 +8,6 @@
#include "base/command_line.h"
#include "base/file_path.h"
#include "base/path_service.h"
-#include "content/public/browser/browser_main_runner.h"
#include "content/public/common/content_switches.h"
#include "content/shell/shell_content_plugin_client.h"
#include "content/shell/shell_content_renderer_client.h"
@@ -18,21 +17,6 @@
namespace ash {
namespace shell {
-namespace {
-
-int ShellBrowserMain(
- const content::MainFunctionParams& main_function_params) {
- scoped_ptr<content::BrowserMainRunner> main_runner(
- content::BrowserMainRunner::Create());
- int exit_code = main_runner->Initialize(main_function_params);
- if (exit_code >= 0)
- return exit_code;
- exit_code = main_runner->Run();
- main_runner->Shutdown();
- return exit_code;
-}
-
-}
ShellMainDelegate::ShellMainDelegate() {
}
@@ -55,25 +39,7 @@ void ShellMainDelegate::PreSandboxStartup() {
InitializeResourceBundle();
}
-void ShellMainDelegate::SandboxInitialized(const std::string& process_type) {
-}
-
-int ShellMainDelegate::RunProcess(
- const std::string& process_type,
- const content::MainFunctionParams& main_function_params) {
- if (process_type != "")
- return -1;
-
- return ShellBrowserMain(main_function_params);
-}
-
-void ShellMainDelegate::ProcessExiting(const std::string& process_type) {
-}
-
#if defined(OS_POSIX)
-content::ZygoteForkDelegate* ShellMainDelegate::ZygoteStarting() {
- return NULL;
-}
void ShellMainDelegate::ZygoteForked() {
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
diff --git a/ash/shell/content_client/shell_main_delegate.h b/ash/shell/content_client/shell_main_delegate.h
index bf04eab..54cc24f 100644
--- a/ash/shell/content_client/shell_main_delegate.h
+++ b/ash/shell/content_client/shell_main_delegate.h
@@ -29,19 +29,7 @@ class ShellMainDelegate : public content::ContentMainDelegate {
virtual bool BasicStartupComplete(int* exit_code) OVERRIDE;
virtual void PreSandboxStartup() OVERRIDE;
- virtual void SandboxInitialized(const std::string& process_type) OVERRIDE;
- virtual int RunProcess(
- const std::string& process_type,
- const content::MainFunctionParams& main_function_params) OVERRIDE;
- virtual void ProcessExiting(const std::string& process_type) OVERRIDE;
-#if defined(OS_MACOSX)
- virtual bool ProcessRegistersWithSystemProcess(
- const std::string& process_type) OVERRIDE;
- virtual bool ShouldSendMachPort(const std::string& process_type) OVERRIDE;
- virtual bool DelaySandboxInitialization(
- const std::string& process_type) OVERRIDE;
-#elif defined(OS_POSIX)
- virtual content::ZygoteForkDelegate* ZygoteStarting() OVERRIDE;
+#if defined(OS_POSIX)
virtual void ZygoteForked() OVERRIDE;
#endif // OS_MACOSX