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

Unified Diff: content/shell/android/java/src/org/chromium/content_shell/ShellManager.java

Issue 26753005: Adding compositor callbacks to RenderWidgetHostViewAndroid (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 7 years, 1 month 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 | « content/public/browser/android/compositor.h ('k') | ui/base/android/window_android.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/android/java/src/org/chromium/content_shell/ShellManager.java
diff --git a/content/shell/android/java/src/org/chromium/content_shell/ShellManager.java b/content/shell/android/java/src/org/chromium/content_shell/ShellManager.java
index a7e3037b85718cbcdf8e8668c9e7d51cbca95c52..c112ede169eeaa02844c1924b7adb6fed12d8b10 100644
--- a/content/shell/android/java/src/org/chromium/content_shell/ShellManager.java
+++ b/content/shell/android/java/src/org/chromium/content_shell/ShellManager.java
@@ -37,7 +37,15 @@ public class ShellManager extends FrameLayout {
public ShellManager(Context context, AttributeSet attrs) {
super(context, attrs);
nativeInit(this);
- mContentViewRenderView = new ContentViewRenderView(context) {
+ }
+
+ /**
+ * @param window The window used to generate all shells.
+ */
+ public void setWindow(WindowAndroid window) {
+ assert window != null;
+ mWindow = window;
+ mContentViewRenderView = new ContentViewRenderView(getContext(), window) {
@Override
protected void onReadyToRender() {
if (sStartup) {
@@ -49,13 +57,6 @@ public class ShellManager extends FrameLayout {
}
/**
- * @param window The window used to generate all shells.
- */
- public void setWindow(WindowAndroid window) {
- mWindow = window;
- }
-
- /**
* @return The window used to generate all shells.
*/
public WindowAndroid getWindow() {
@@ -87,6 +88,7 @@ public class ShellManager extends FrameLayout {
@SuppressWarnings("unused")
@CalledByNative
private Object createShell() {
+ assert mContentViewRenderView != null;
LayoutInflater inflater =
(LayoutInflater) getContext().getSystemService(Context.LAYOUT_INFLATER_SERVICE);
Shell shellView = (Shell) inflater.inflate(R.layout.shell_view, null);
« no previous file with comments | « content/public/browser/android/compositor.h ('k') | ui/base/android/window_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698