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

Unified Diff: shell/context.cc

Issue 848013004: Make --gdb work for android (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Fix nits Created 5 years, 11 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 | « no previous file | shell/desktop/mojo_main.cc » ('j') | sky/tools/mojo_cache_linker.py » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: shell/context.cc
diff --git a/shell/context.cc b/shell/context.cc
index d3a86132b5eea47a4d66fa25aa02a6d1e8cd091d..5f776e3fa1f8dcda6c962c85821885a0c6ca82da 100644
--- a/shell/context.cc
+++ b/shell/context.cc
@@ -6,6 +6,7 @@
#include <vector>
+#include "base/base_switches.h"
#include "base/bind.h"
#include "base/command_line.h"
#include "base/files/file_path.h"
@@ -136,6 +137,11 @@ void Context::EnsureEmbedderIsInitialized() {
}
bool Context::Init() {
+ base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
+
+ if (command_line->HasSwitch(switches::kWaitForDebugger))
+ base::debug::WaitForDebugger(60, true);
+
EnsureEmbedderIsInitialized();
task_runners_.reset(
new TaskRunners(base::MessageLoop::current()->message_loop_proxy()));
@@ -143,8 +149,6 @@ bool Context::Init() {
for (size_t i = 0; i < arraysize(kLocalMojoURLs); ++i)
mojo_url_resolver_.AddLocalFileMapping(GURL(kLocalMojoURLs[i]));
- base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
-
if (command_line->HasSwitch(switches::kEnableExternalApplications)) {
listener_ = ExternalApplicationListener::Create(
task_runners_->shell_runner(), task_runners_->io_runner());
« no previous file with comments | « no previous file | shell/desktop/mojo_main.cc » ('j') | sky/tools/mojo_cache_linker.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698