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

Unified Diff: mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java

Issue 47343002: Pass app URL to mojo_shell on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 2 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/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoMain.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java
diff --git a/mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java b/mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java
index 7acf28350aa18a2a6611ec1e59d635b708c1ff73..4c117bf2a2422effde48236d6245e658557fc774 100644
--- a/mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java
+++ b/mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoShellActivity.java
@@ -4,8 +4,9 @@
package org.chromium.mojo_shell_apk;
-import android.os.Bundle;
import android.app.Activity;
+import android.content.Intent;
+import android.os.Bundle;
import android.util.Log;
import org.chromium.mojo_shell_apk.LibraryLoader;
@@ -30,7 +31,13 @@ public class MojoShellActivity extends Activity {
finish();
return;
}
- MojoMain.start(this);
- Log.i(TAG, "Mojo started.");
+
+ String appUrl = getUrlFromIntent(getIntent());
+ MojoMain.start(this, appUrl);
+ Log.i(TAG, "Mojo started: " + appUrl);
+ }
+
+ private static String getUrlFromIntent(Intent intent) {
+ return intent != null ? intent.getDataString() : null;
}
}
« no previous file with comments | « mojo/shell/android/shell_apk/src/org/chromium/mojo_shell_apk/MojoMain.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698