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

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

Issue 981703002: Ensure WebContentsObserver.destroy is called (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix build Created 5 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 | « no previous file | content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsObserverProxy.java » ('j') | 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/webcontents/WebContentsImpl.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java b/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
index f7a82e6992d0722a52d2bfc47728b1fcb3211cd7..216be3a971dbc198a1cccc4cf099d39f861eac0b 100644
--- a/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
+++ b/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
@@ -331,10 +331,6 @@ import org.chromium.content_public.browser.WebContentsObserver;
public void removeObserver(WebContentsObserver observer) {
if (mObserverProxy == null) return;
mObserverProxy.removeObserver(observer);
- if (!mObserverProxy.hasObservers()) {
- mObserverProxy.destroy();
- mObserverProxy = null;
- }
}
// This is static to avoid exposing a public destroy method on the native side of this class.
« no previous file with comments | « no previous file | content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsObserverProxy.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698