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

Side by Side Diff: chrome/browser/task_manager/task_manager.cc

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 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
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/task_manager/task_manager.h" 5 #include "chrome/browser/task_manager/task_manager.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/i18n/number_formatting.h" 8 #include "base/i18n/number_formatting.h"
9 #include "base/i18n/rtl.h" 9 #include "base/i18n/rtl.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 1530 matching lines...) Expand 10 before | Expand all | Expand 10 after
1541 void TaskManager::OnWindowClosed() { 1541 void TaskManager::OnWindowClosed() {
1542 model_->StopUpdating(); 1542 model_->StopUpdating();
1543 } 1543 }
1544 1544
1545 void TaskManager::ModelChanged() { 1545 void TaskManager::ModelChanged() {
1546 model_->ModelChanged(); 1546 model_->ModelChanged();
1547 } 1547 }
1548 1548
1549 // static 1549 // static
1550 TaskManager* TaskManager::GetInstance() { 1550 TaskManager* TaskManager::GetInstance() {
1551 return Singleton<TaskManager>::get(); 1551 return base::Singleton<TaskManager>::get();
1552 } 1552 }
1553 1553
1554 void TaskManager::OpenAboutMemory(chrome::HostDesktopType desktop_type) { 1554 void TaskManager::OpenAboutMemory(chrome::HostDesktopType desktop_type) {
1555 Profile* profile = ProfileManager::GetLastUsedProfileAllowedByPolicy(); 1555 Profile* profile = ProfileManager::GetLastUsedProfileAllowedByPolicy();
1556 if (profile->IsGuestSession() && !g_browser_process->local_state()-> 1556 if (profile->IsGuestSession() && !g_browser_process->local_state()->
1557 GetBoolean(prefs::kBrowserGuestModeEnabled)) { 1557 GetBoolean(prefs::kBrowserGuestModeEnabled)) {
1558 UserManager::Show(base::FilePath(), 1558 UserManager::Show(base::FilePath(),
1559 profiles::USER_MANAGER_NO_TUTORIAL, 1559 profiles::USER_MANAGER_NO_TUTORIAL,
1560 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_MEMORY); 1560 profiles::USER_MANAGER_SELECT_PROFILE_CHROME_MEMORY);
1561 return; 1561 return;
1562 } 1562 }
1563 1563
1564 chrome::NavigateParams params( 1564 chrome::NavigateParams params(
1565 profile, GURL(chrome::kChromeUIMemoryURL), ui::PAGE_TRANSITION_LINK); 1565 profile, GURL(chrome::kChromeUIMemoryURL), ui::PAGE_TRANSITION_LINK);
1566 params.disposition = NEW_FOREGROUND_TAB; 1566 params.disposition = NEW_FOREGROUND_TAB;
1567 params.host_desktop_type = desktop_type; 1567 params.host_desktop_type = desktop_type;
1568 chrome::Navigate(&params); 1568 chrome::Navigate(&params);
1569 } 1569 }
1570 1570
1571 TaskManager::TaskManager() 1571 TaskManager::TaskManager()
1572 : model_(new TaskManagerModel(this)) { 1572 : model_(new TaskManagerModel(this)) {
1573 } 1573 }
1574 1574
1575 TaskManager::~TaskManager() { 1575 TaskManager::~TaskManager() {
1576 } 1576 }
OLDNEW
« no previous file with comments | « chrome/browser/task_manager/task_manager.h ('k') | chrome/browser/themes/theme_service_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698