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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java

Issue 2299453002: Restrict number of BlimpContents to [0, 1] (Closed)
Patch Set: patch failure fix Created 4 years, 4 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 | « blimp/client/public/blimp_client_context.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java b/chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java
index e914ba5da5ff5d7812c01579ecc70b25ee13ad2b..6ae4ba3efe7603b59a09ba9506a3edcd8d77d2b9 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java
@@ -1503,7 +1503,11 @@ public class Tab implements ViewGroup.OnHierarchyChangeListener,
Profile profile = Profile.getLastUsedProfile();
if (mIncognito) profile = profile.getOffTheRecordProfile();
mBlimpContents = nativeInitBlimpContents(mNativeTabAndroid, profile);
- getBlimpContents().addObserver(new TabBlimpContentsObserver(this));
+ if (mBlimpContents != null) {
+ getBlimpContents().addObserver(new TabBlimpContentsObserver(this));
+ } else {
+ mBlimp = false;
+ }
}
boolean creatingWebContents = webContents == null;
« no previous file with comments | « blimp/client/public/blimp_client_context.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698