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

Unified Diff: content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java

Issue 1731673002: Add tab reparenting (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove test Created 4 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
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java b/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
index 19c37376a716ea9d7fff9451d2c04dcf1a11cb07..9c2105f3bd45379ce2bc120de6f6bc7a2b4b6be5 100644
--- a/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
+++ b/content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
@@ -786,6 +786,16 @@ public class ContentViewCore implements AccessibilityStateChangeListener, Screen
mWebContentsObserver = new ContentViewWebContentsObserver(this);
}
+ /**
+ * Updates the native {@link ContentViewCore} with a new window. This moves the NativeView and
+ * attached it to the new NativeWindow linked with the given {@link WindowAndroid}.
+ * @param windowAndroid The new {@link WindowAndroid} for this {@link ContentViewCore}.
+ */
+ public void updateWindowAndroid(WindowAndroid windowAndroid) {
+ long windowNativePointer = windowAndroid == null ? 0 : windowAndroid.getNativePointer();
+ nativeUpdateWindowAndroid(mNativeContentViewCore, windowNativePointer);
+ }
+
@VisibleForTesting
public void createContentViewAndroidDelegate() {
mViewAndroidDelegate = new ContentViewAndroidDelegate(mContainerView, mRenderCoordinates);
@@ -3210,6 +3220,8 @@ public class ContentViewCore implements AccessibilityStateChangeListener, Screen
long windowAndroidPtr, HashSet<Object> retainedObjectSet);
private static native ContentViewCore nativeFromWebContentsAndroid(WebContents webContents);
+ private native void nativeUpdateWindowAndroid(
+ long nativeContentViewCoreImpl, long windowAndroidPtr);
private native WebContents nativeGetWebContentsAndroid(long nativeContentViewCoreImpl);
private native WindowAndroid nativeGetJavaWindowAndroid(long nativeContentViewCoreImpl);
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698