Chromium Code Reviews| Index: chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastShellActivity.java |
| diff --git a/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastShellActivity.java b/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastShellActivity.java |
| index 6c576f55ee091d1a7d0a1aee00be44d679eb954e..879a58fad4435f1a9c2c7507a0e899d8d981bf14 100644 |
| --- a/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastShellActivity.java |
| +++ b/chromecast/browser/android/apk/src/org/chromium/chromecast/shell/CastShellActivity.java |
| @@ -21,7 +21,6 @@ import android.widget.Toast; |
| import org.chromium.base.Log; |
| import org.chromium.content.browser.ActivityContentVideoViewEmbedder; |
| -import org.chromium.content.browser.ContentVideoViewEmbedder; |
| import org.chromium.content.browser.ContentViewClient; |
| import org.chromium.content.browser.ContentViewCore; |
| import org.chromium.ui.base.WindowAndroid; |
| @@ -115,12 +114,12 @@ public class CastShellActivity extends Activity { |
| Log.d(TAG, "onCreate startupUrl: %s", url); |
| mNativeCastWindow = mCastWindowManager.launchCastWindow(url); |
| - getActiveContentViewCore().setContentViewClient(new ContentViewClient() { |
| - @Override |
| - public ContentVideoViewEmbedder getContentVideoViewEmbedder() { |
| - return new ActivityContentVideoViewEmbedder(CastShellActivity.this); |
| - } |
| - }); |
| + getActiveContentViewCore().setContentViewClient(new ContentViewClient()); |
| + CastWindowAndroid shellView = getActiveCastWindow(); |
| + if (shellView != null) { |
| + shellView.setContentVideoViewEmbedder( |
|
Simeon
2016/09/28 00:24:52
I think a better way to do this is to pass the Con
Jinsuk Kim
2016/09/28 03:58:52
While appreciating your suggestion, I tried a simp
|
| + new ActivityContentVideoViewEmbedder(CastShellActivity.this)); |
|
Simeon
2016/09/28 00:24:52
Now that this line isn't in an anonymous class, we
Jinsuk Kim
2016/09/28 03:58:52
Removed.
|
| + } |
| } |
| @Override |