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

Unified Diff: ios/chrome/browser/ui/browser_view_controller.mm

Issue 2759563003: Display the preload Tab if it replaces the current Tab. (Closed)
Patch Set: only display when active Created 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/ui/browser_view_controller.mm
diff --git a/ios/chrome/browser/ui/browser_view_controller.mm b/ios/chrome/browser/ui/browser_view_controller.mm
index 83513d14823aefbee845c27c18342b1700d6507d..e83a5c533d0229abb781bda7b73f1fea507fd3f9 100644
--- a/ios/chrome/browser/ui/browser_view_controller.mm
+++ b/ios/chrome/browser/ui/browser_view_controller.mm
@@ -4574,6 +4574,10 @@ - (void)tabModel:(TabModel*)model
atIndex:(NSUInteger)index {
[self uninstallDelegatesForTab:oldTab];
[self installDelegatesForTab:newTab];
+
+ // Add |newTab|'s view to the hierarchy if it's the current Tab.
+ if (self.active && model.currentTab == newTab)
+ [self displayTab:newTab isNewSelection:NO];
}
// A tab has been removed, remove its views from display if necessary.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698