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

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

Issue 2353063005: Refactor ContentViewClient (1/6) (Closed)
Patch Set: rebased Created 4 years, 3 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: 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 1769e37d7d2d11e4e08528366a2ebe40eb6ed1f5..fa4838600294d8b8c0b14d2cab92f0d6c283b355 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
@@ -17,6 +17,7 @@ import android.widget.LinearLayout;
import org.chromium.base.annotations.CalledByNative;
import org.chromium.base.annotations.JNINamespace;
+import org.chromium.content.browser.ContentVideoViewEmbedder;
import org.chromium.content.browser.ContentView;
import org.chromium.content.browser.ContentViewCore;
import org.chromium.content.browser.ContentViewRenderView;
@@ -40,6 +41,7 @@ public class CastWindowAndroid extends LinearLayout {
private ContentViewCore mContentViewCore;
private ContentViewRenderView mContentViewRenderView;
+ private ContentVideoViewEmbedder mContentVideoViewEmbedder;
private NavigationController mNavigationController;
private int mRenderProcessId;
private WebContents mWebContents;
@@ -127,7 +129,7 @@ public class CastWindowAndroid extends LinearLayout {
@CalledByNative
private void initFromNativeWebContents(WebContents webContents, int renderProcessId) {
Context context = getContext();
- mContentViewCore = new ContentViewCore(context);
+ mContentViewCore = new ContentViewCore(context, "");
boliu 2016/09/27 23:28:45 ditto
Jinsuk Kim 2016/09/28 03:58:52 sanfin@ please see if the product version I picked
ContentView view = ContentView.createContentView(context, mContentViewCore);
mContentViewCore.initialize(ViewAndroidDelegate.createBasicDelegate(view), view,
webContents, mWindow);
@@ -156,6 +158,15 @@ public class CastWindowAndroid extends LinearLayout {
};
}
+ public void setContentVideoViewEmbedder(ContentVideoViewEmbedder embedder) {
+ mContentVideoViewEmbedder = embedder;
+ }
+
+ @CalledByNative
+ public ContentVideoViewEmbedder getContentVideoViewEmbedder() {
Simeon 2016/09/28 00:24:52 This does not need to be public. But if you manag
Jinsuk Kim 2016/09/28 03:58:52 Changed to private. I think the context of CastWin
+ return mContentVideoViewEmbedder;
+ }
+
/**
* @return The {@link ViewGroup} currently shown by this Shell.
*/

Powered by Google App Engine
This is Rietveld 408576698