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

Unified Diff: mojo/apps/js/mojo_runner_delegate.cc

Issue 179803007: Refactors parts of gin: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix gin_shell Created 6 years, 10 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 | « mojo/apps/js/mojo_runner_delegate.h ('k') | mojo/apps/js/test/run_js_tests.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/apps/js/mojo_runner_delegate.cc
diff --git a/mojo/apps/js/mojo_runner_delegate.cc b/mojo/apps/js/mojo_runner_delegate.cc
index c160f167682e9c780c3c853a931f3a9dba3c3939..58cb3336fe42ed5747ea201df6eb3a3ab5186bc7 100644
--- a/mojo/apps/js/mojo_runner_delegate.cc
+++ b/mojo/apps/js/mojo_runner_delegate.cc
@@ -35,7 +35,7 @@ std::vector<base::FilePath> GetModuleSearchPaths() {
void StartCallback(base::WeakPtr<gin::Runner> runner,
MojoHandle pipe,
v8::Handle<v8::Value> module) {
- v8::Isolate* isolate = runner->isolate();
+ v8::Isolate* isolate = runner->GetContextHolder()->isolate();
v8::Handle<v8::Function> start;
CHECK(gin::ConvertFromV8(isolate, module, &start));
@@ -63,13 +63,14 @@ void MojoRunnerDelegate::Start(gin::Runner* runner,
MojoHandle pipe,
const std::string& module) {
gin::Runner::Scope scope(runner);
- gin::ModuleRegistry* registry = gin::ModuleRegistry::From(runner->context());
- registry->LoadModule(runner->isolate(), module,
+ gin::ModuleRegistry* registry =
+ gin::ModuleRegistry::From(runner->GetContextHolder()->context());
+ registry->LoadModule(runner->GetContextHolder()->isolate(), module,
base::Bind(StartCallback, runner->GetWeakPtr(), pipe));
AttemptToLoadMoreModules(runner);
}
-void MojoRunnerDelegate::UnhandledException(gin::Runner* runner,
+void MojoRunnerDelegate::UnhandledException(gin::ShellRunner* runner,
gin::TryCatch& try_catch) {
gin::ModuleRunnerDelegate::UnhandledException(runner, try_catch);
LOG(ERROR) << try_catch.GetStackTrace();
« no previous file with comments | « mojo/apps/js/mojo_runner_delegate.h ('k') | mojo/apps/js/test/run_js_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698