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

Unified Diff: chrome/browser/android/tab_android.cc

Issue 1026983002: Allow adding an overlay not attached to the tab layer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: attachToCC -> attachLayer Created 5 years, 9 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 | « chrome/android/java/src/org/chromium/chrome/browser/tab/TransitionPageHelper.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/tab_android.cc
diff --git a/chrome/browser/android/tab_android.cc b/chrome/browser/android/tab_android.cc
index e9289de54c9a5f06a4fc4123ab76799c2c6482d4..c6d89f57f771171e7ba467fbd41163a7b04ff067 100644
--- a/chrome/browser/android/tab_android.cc
+++ b/chrome/browser/android/tab_android.cc
@@ -844,7 +844,8 @@ void TabAndroid::DetachOverlayContentViewCore(JNIEnv* env,
jcontent_view_core);
DCHECK(content_view_core);
- content_view_core->GetLayer()->RemoveFromParent();
+ if (content_view_core->GetLayer()->parent() == content_layer_)
+ content_view_core->GetLayer()->RemoveFromParent();
}
static void Init(JNIEnv* env, jobject obj) {
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/tab/TransitionPageHelper.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698