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

Unified Diff: content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java

Issue 2640143002: Allow autoplay unmuted for WebAPK in the manifest scope (Closed)
Patch Set: fixed Android build and layout tests Created 3 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
Index: content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java
diff --git a/content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java b/content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java
index 7df71bb4b475e0d954316fe28455ab670b5a0893..2aa519d0feb9b4b85ed0449fb4c03dbf9f92941b 100644
--- a/content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java
+++ b/content/public/android/java/src/org/chromium/content/app/ChildProcessServiceImpl.java
@@ -38,6 +38,7 @@ import org.chromium.content.common.IChildProcessCallback;
import org.chromium.content.common.IChildProcessService;
import org.chromium.content.common.SurfaceWrapper;
+import java.util.ArrayList;
import java.util.concurrent.Semaphore;
import java.util.concurrent.atomic.AtomicReference;
@@ -74,6 +75,7 @@ public class ChildProcessServiceImpl {
private ChromiumLinkerParams mLinkerParams;
// Child library process type.
private int mLibraryProcessType;
+ private String[] mAdditionalCommandLine;
private static AtomicReference<Context> sContext = new AtomicReference<>(null);
private boolean mLibraryInitialized;
@@ -196,7 +198,19 @@ public class ChildProcessServiceImpl {
mMainThread.wait();
}
}
- CommandLine.init(mCommandLineParams);
+
+ ArrayList<String> fullCommandLine = new ArrayList<String>();
+ for (String param : mCommandLineParams) fullCommandLine.add(param);
+ if (mAdditionalCommandLine != null) {
+ for (String param : mAdditionalCommandLine) {
+ fullCommandLine.add(param);
+ }
+ }
+ String[] fullCommandLineArray = new String[fullCommandLine.size()];
+ for (int i = 0; i < fullCommandLine.size(); ++i) {
+ fullCommandLineArray[i] = fullCommandLine.get(i);
+ }
+ CommandLine.init(fullCommandLineArray);
if (ContentSwitches.SWITCH_RENDERER_PROCESS.equals(
CommandLine.getInstance().getSwitchValue(
@@ -327,6 +341,7 @@ public class ChildProcessServiceImpl {
// See onCreate().
mLinkerParams = new ChromiumLinkerParams(intent);
mLibraryProcessType = ChildProcessCreationParams.getLibraryProcessType(intent);
+ mAdditionalCommandLine = ChildProcessCreationParams.getAdditionalCommandLine(intent);
mMainThread.notifyAll();
}
}

Powered by Google App Engine
This is Rietveld 408576698