summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-21 19:39:02 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-21 19:39:02 +0000
commit27d4821177b70eb47b02c9b922889a40f9d8a9eb (patch)
tree7f2f2cc4b6f504d8701a848e26c0636b1e787e0f /chrome
parenta552526e396f22349a510e52045425ad0ea6f250 (diff)
downloadchromium_src-27d4821177b70eb47b02c9b922889a40f9d8a9eb.zip
chromium_src-27d4821177b70eb47b02c9b922889a40f9d8a9eb.tar.gz
chromium_src-27d4821177b70eb47b02c9b922889a40f9d8a9eb.tar.bz2
Reverts parts of http://src.chromium.org/viewvc/chrome?view=rev&revision=16474 which aren't needed anymore.
Review URL: http://codereview.chromium.org/113669 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16642 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/browser_process_impl.cc8
-rw-r--r--chrome/browser/task_manager.cc17
-rw-r--r--chrome/browser/task_manager.h7
3 files changed, 0 insertions, 32 deletions
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc
index bf97e56..18e3a83 100644
--- a/chrome/browser/browser_process_impl.cc
+++ b/chrome/browser/browser_process_impl.cc
@@ -26,7 +26,6 @@
#include "chrome/browser/renderer_host/render_process_host.h"
#include "chrome/browser/renderer_host/resource_dispatcher_host.h"
#include "chrome/browser/safe_browsing/safe_browsing_service.h"
-#include "chrome/browser/task_manager.h"
#include "chrome/common/chrome_paths.h"
#include "chrome/common/chrome_switches.h"
#include "chrome/common/notification_service.h"
@@ -213,13 +212,6 @@ BrowserProcessImpl::~BrowserProcessImpl() {
print_job_manager_->OnQuit();
print_job_manager_.reset();
-#if defined(OS_WIN) || defined(OS_LINUX)
- // TODO(port): Remove #ifdef when TaskManager is ported to Mac.
- // Make sure that TaskManager destroys things that can't be safely destroyed
- // by AtExitManager. Does nothing if TaskManager has not been initialized.
- TaskManager::EnsureShutdown();
-#endif // defined(OS_WIN) || defined(OS_LINUX)
-
// Now OK to destroy NotificationService.
main_notification_service_.reset();
diff --git a/chrome/browser/task_manager.cc b/chrome/browser/task_manager.cc
index c4e186b..7a7a252 100644
--- a/chrome/browser/task_manager.cc
+++ b/chrome/browser/task_manager.cc
@@ -688,9 +688,6 @@ bool TaskManagerModel::GetProcessMetricsForRows(
////////////////////////////////////////////////////////////////////////////////
// static
-bool TaskManager::initialized_ = false;
-
-// static
void TaskManager::RegisterPrefs(PrefService* prefs) {
prefs->RegisterDictionaryPref(prefs::kTaskManagerWindowPlacement);
}
@@ -698,7 +695,6 @@ void TaskManager::RegisterPrefs(PrefService* prefs) {
TaskManager::TaskManager()
: ALLOW_THIS_IN_INITIALIZER_LIST(model_(new TaskManagerModel(this))) {
Init();
- initialized_ = true;
}
TaskManager::~TaskManager() {
@@ -715,19 +711,6 @@ void TaskManager::Close() {
model_->Clear();
}
-// static
-void TaskManager::EnsureShutdown() {
- if (!initialized_)
- return;
-
- // TaskManager is a singleton, which means it's destroyed by AtExitManager.
- // At that point it can't register AtExit callbacks etc. It turns out that
- // view destruction code does it on Windows, so we destroy the view now.
- TaskManager* task_manager = GetInstance();
- task_manager->view_.reset();
- initialized_ = false;
-}
-
bool TaskManager::BrowserProcessIsSelected() {
if (!view_.get())
return false;
diff --git a/chrome/browser/task_manager.h b/chrome/browser/task_manager.h
index a66cb8f..d58a21e 100644
--- a/chrome/browser/task_manager.h
+++ b/chrome/browser/task_manager.h
@@ -98,10 +98,6 @@ class TaskManager {
// Close the task manager.
void Close();
- // Do the cleanup that can't be done during singleton destruction by
- // AtExitManager. Does nothing if the TaskManager hasn't been initialized.
- static void EnsureShutdown();
-
// Returns true if the current selection includes the browser process.
bool BrowserProcessIsSelected();
@@ -137,9 +133,6 @@ class TaskManager {
// Returns the singleton instance (and initializes it if necessary).
static TaskManager* GetInstance();
- // Flag set to true when TaskManager is initialized.
- static bool initialized_;
-
// The model used for gathering and processing task data. It is ref counted
// because it is passed as a parameter to MessageLoop::InvokeLater().
scoped_refptr<TaskManagerModel> model_;