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

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

Issue 2899053004: [Home] Ensure incognito tab model is created when NTP opened (Closed)
Patch Set: [Home] Ensure incognito tab model is created when NTP opened Created 3 years, 7 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
Index: chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
index 4a857b1a9c4a807aa7251adafae7c07af2404407..0aa92d9a380f8f77efc0bd9f97a8abc56926efd7 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -1034,11 +1034,14 @@ public class ChromeTabbedActivity extends ChromeActivity implements OverviewMode
}
if (getBottomSheet() != null) {
- if (getBottomSheet().isShowingNewTab()) {
+ // If the bottom sheet new tab UI is showing and the tab open type is not
+ // already OPEN_NEW_TAB or OPEN_NEW_INCOGNITO_TAB, set the open type so that a real
+ // new tab will be created and added to the appropriate model.
+ if (getBottomSheet().isShowingNewTab() && tabOpenType != TabOpenType.OPEN_NEW_TAB
+ && tabOpenType != TabOpenType.OPEN_NEW_INCOGNITO_TAB) {
tabOpenType = mTabModelSelectorImpl.isIncognitoSelected()
? TabOpenType.OPEN_NEW_INCOGNITO_TAB
: TabOpenType.OPEN_NEW_TAB;
- getBottomSheet().onProcessUrlViewIntent();
Theresa 2017/05/24 16:52:08 BottomSheetNewTabController hides the new tab UI w
}
// Either a new tab is opening, a tab is being clobbered, or a tab is being brought

Powered by Google App Engine
This is Rietveld 408576698