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

Unified Diff: content/app/android/content_main.cc

Issue 190853004: Convert ContentMain to take a struct instead of parameters that vary depending on the platform. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 6 years, 9 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
Index: content/app/android/content_main.cc
===================================================================
--- content/app/android/content_main.cc (revision 255697)
+++ content/app/android/content_main.cc (working copy)
@@ -16,9 +16,9 @@
#include "jni/ContentMain_jni.h"
using base::LazyInstance;
-using content::ContentMainRunner;
-using content::ContentMainDelegate;
+namespace content {
+
namespace {
LazyInstance<scoped_ptr<ContentMainRunner> > g_content_runner =
LAZY_INSTANCE_INITIALIZER;
@@ -28,8 +28,6 @@
} // namespace
-namespace content {
-
static void InitApplicationContext(JNIEnv* env, jclass clazz, jobject context) {
base::android::ScopedJavaLocalRef<jobject> scoped_context(env, context);
base::android::InitApplicationContext(env, scoped_context);
@@ -43,9 +41,9 @@
// request then we have to call this a second time to finish starting the
// browser synchronously.
if (!g_content_runner.Get().get()) {
+ ContentMainParams params(g_content_main_delegate.Get().get());
g_content_runner.Get().reset(ContentMainRunner::Create());
- g_content_runner.Get()->Initialize(
- 0, NULL, g_content_main_delegate.Get().get());
+ g_content_runner.Get()->Initialize(&params);
}
return g_content_runner.Get()->Run();
}

Powered by Google App Engine
This is Rietveld 408576698