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

Unified Diff: gin/shell/gin_main.cc

Issue 76353002: Introduce a Gin class instead of using global functions to control gin (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 7 years, 1 month 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 | « gin/runner_unittest.cc ('k') | gin/test/file_runner.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/shell/gin_main.cc
diff --git a/gin/shell/gin_main.cc b/gin/shell/gin_main.cc
index ca984f7573846e13b2b8452ff9334ade3ded004d..e1d95bbd472f476058cfb98e5afee4a68703b313 100644
--- a/gin/shell/gin_main.cc
+++ b/gin/shell/gin_main.cc
@@ -6,8 +6,9 @@
#include "base/bind.h"
#include "base/command_line.h"
#include "base/file_util.h"
+#include "base/i18n/icu_util.h"
#include "base/message_loop/message_loop.h"
-#include "gin/initialize.h"
+#include "gin/gin.h"
#include "gin/modules/console.h"
#include "gin/modules/module_runner_delegate.h"
#include "gin/test/file_runner.h"
@@ -58,12 +59,14 @@ class ShellRunnerDelegate : public ModuleRunnerDelegate {
int main(int argc, char** argv) {
base::AtExitManager at_exit;
CommandLine::Init(argc, argv);
- gin::Initialize();
+ base::i18n::InitializeICU();
+
+ gin::Gin instance;
base::MessageLoop message_loop;
gin::ShellRunnerDelegate delegate;
- gin::Runner runner(&delegate, v8::Isolate::GetCurrent());
+ gin::Runner runner(&delegate, instance.isolate());
CommandLine::StringVector args = CommandLine::ForCurrentProcess()->GetArgs();
for (CommandLine::StringVector::const_iterator it = args.begin();
« no previous file with comments | « gin/runner_unittest.cc ('k') | gin/test/file_runner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698