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

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

Issue 10696148: Move TabStripModelDelegate off Browser into its own class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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 unified diff | Download patch | Annotate | Revision Log
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 "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/environment.h" 10 #include "base/environment.h"
(...skipping 696 matching lines...) Expand 10 before | Expand all | Expand 10 after
707 params.tabstrip_index = index; 707 params.tabstrip_index = index;
708 params.tabstrip_add_types = add_types; 708 params.tabstrip_add_types = add_types;
709 params.extension_app_id = tabs[i].app_id; 709 params.extension_app_id = tabs[i].app_id;
710 chrome::Navigate(&params); 710 chrome::Navigate(&params);
711 711
712 first_tab = false; 712 first_tab = false;
713 } 713 }
714 if (!chrome::GetActiveWebContents(browser)) { 714 if (!chrome::GetActiveWebContents(browser)) {
715 // TODO: this is a work around for 110909. Figure out why it's needed. 715 // TODO: this is a work around for 110909. Figure out why it's needed.
716 if (!browser->tab_count()) 716 if (!browser->tab_count())
717 browser->AddBlankTab(true); 717 chrome::AddBlankTab(browser, true);
718 else 718 else
719 chrome::ActivateTabAt(browser, 0, false); 719 chrome::ActivateTabAt(browser, 0, false);
720 } 720 }
721 721
722 browser->window()->Show(); 722 browser->window()->Show();
723 // TODO(jcampan): http://crbug.com/8123 we should not need to set the initial 723 // TODO(jcampan): http://crbug.com/8123 we should not need to set the initial
724 // focus explicitly. 724 // focus explicitly.
725 chrome::GetActiveWebContents(browser)->GetView()->SetInitialFocus(); 725 chrome::GetActiveWebContents(browser)->GetView()->SetInitialFocus();
726 726
727 return browser; 727 return browser;
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
861 // New: 861 // New:
862 prefs->GetString(prefs::kHomePage), 862 prefs->GetString(prefs::kHomePage),
863 prefs->GetBoolean(prefs::kHomePageIsNewTabPage), 863 prefs->GetBoolean(prefs::kHomePageIsNewTabPage),
864 prefs->GetBoolean(prefs::kShowHomeButton), 864 prefs->GetBoolean(prefs::kShowHomeButton),
865 // Backup: 865 // Backup:
866 backup_homepage, 866 backup_homepage,
867 backup_homepage_is_ntp, 867 backup_homepage_is_ntp,
868 backup_show_home_button)); 868 backup_show_home_button));
869 } 869 }
870 } 870 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc ('k') | chrome/browser/ui/tabs/tab_strip_model_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698