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

Side by Side Diff: chrome/browser/ui/startup/startup_browser_creator_impl.cc

Issue 11392004: Remove TabContents from AddBlankTabAt, kill AddBlankTab. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc ('k') | chrome/browser/ui/tabs/tab_strip_model.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/startup/startup_browser_creator_impl.h" 5 #include "chrome/browser/ui/startup/startup_browser_creator_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 850 matching lines...) Expand 10 before | Expand all | Expand 10 after
861 } 861 }
862 #endif 862 #endif
863 863
864 chrome::Navigate(&params); 864 chrome::Navigate(&params);
865 865
866 first_tab = false; 866 first_tab = false;
867 } 867 }
868 if (!chrome::GetActiveWebContents(browser)) { 868 if (!chrome::GetActiveWebContents(browser)) {
869 // TODO: this is a work around for 110909. Figure out why it's needed. 869 // TODO: this is a work around for 110909. Figure out why it's needed.
870 if (!browser->tab_count()) 870 if (!browser->tab_count())
871 chrome::AddBlankTab(browser, true); 871 chrome::AddBlankTabAt(browser, -1, true);
872 else 872 else
873 chrome::ActivateTabAt(browser, 0, false); 873 chrome::ActivateTabAt(browser, 0, false);
874 } 874 }
875 875
876 // The default behaviour is to show the window, as expressed by the default 876 // The default behaviour is to show the window, as expressed by the default
877 // value of StartupBrowserCreated::show_main_browser_window_. If this was set 877 // value of StartupBrowserCreated::show_main_browser_window_. If this was set
878 // to true ahead of this place, it means another task must have been spawned 878 // to true ahead of this place, it means another task must have been spawned
879 // to take care of that. 879 // to take care of that.
880 if (!browser_creator_ || browser_creator_->show_main_browser_window()) 880 if (!browser_creator_ || browser_creator_->show_main_browser_window())
881 browser->window()->Show(); 881 browser->window()->Show();
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
1042 1042
1043 #if !defined(OS_WIN) || defined(USE_AURA) 1043 #if !defined(OS_WIN) || defined(USE_AURA)
1044 // static 1044 // static
1045 bool StartupBrowserCreatorImpl::OpenStartupURLsInExistingBrowser( 1045 bool StartupBrowserCreatorImpl::OpenStartupURLsInExistingBrowser(
1046 Profile* profile, 1046 Profile* profile,
1047 const std::vector<GURL>& startup_urls) { 1047 const std::vector<GURL>& startup_urls) {
1048 return false; 1048 return false;
1049 } 1049 }
1050 #endif 1050 #endif
1051 1051
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc ('k') | chrome/browser/ui/tabs/tab_strip_model.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698