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

Unified Diff: chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java

Issue 773313002: Expose render_process_id to CastShellActivity. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit fixes. Created 6 years 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 | « no previous file | chromecast/browser/android/cast_window_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java
diff --git a/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java b/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java
index b66b9f8185ce1a54bcc3a79bc98056aaeb74335d..edb95be420255a8cc6c1919696ddf45abf3a0481 100644
--- a/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java
+++ b/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastWindowAndroid.java
@@ -40,6 +40,7 @@ public class CastWindowAndroid extends LinearLayout {
private ContentViewCore mContentViewCore;
private ContentViewRenderView mContentViewRenderView;
private NavigationController mNavigationController;
+ private int mRenderProcessId;
private WebContents mWebContents;
private WebContentsObserver mWebContentsObserver;
private WindowAndroid mWindow;
@@ -97,6 +98,13 @@ public class CastWindowAndroid extends LinearLayout {
}
/**
+ * Returns the render_process_id for the associated web contents
+ */
+ public int getRenderProcessId() {
+ return mRenderProcessId;
+ }
+
+ /**
* Given a URI String, performs minimal normalization to attempt to build a usable URL from it.
* @param uriString The passed-in path to be normalized.
* @return The normalized URL, as a string.
@@ -116,13 +124,14 @@ public class CastWindowAndroid extends LinearLayout {
*/
@SuppressWarnings("unused")
@CalledByNative
- private void initFromNativeWebContents(long nativeWebContents) {
+ private void initFromNativeWebContents(long nativeWebContents, int renderProcessId) {
Context context = getContext();
mContentViewCore = new ContentViewCore(context);
ContentView view = ContentView.newInstance(context, mContentViewCore);
mContentViewCore.initialize(view, view, nativeWebContents, mWindow);
mWebContents = mContentViewCore.getWebContents();
mNavigationController = mWebContents.getNavigationController();
+ mRenderProcessId = renderProcessId;
if (getParent() != null) mContentViewCore.onShow();
((FrameLayout) findViewById(R.id.contentview_holder)).addView(view,
« no previous file with comments | « no previous file | chromecast/browser/android/cast_window_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698