summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorandybons@chromium.org <andybons@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-11 20:08:55 +0000
committerandybons@chromium.org <andybons@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-11 20:08:55 +0000
commitfdb4c7db1703189d9d26526e12c03cab7dd11655 (patch)
treef3817b489c7b0b57785fcbd32c2dbdb2341d14ff /chrome/browser
parent02afb591a63b446ad8a2db98654273b6675700a3 (diff)
downloadchromium_src-fdb4c7db1703189d9d26526e12c03cab7dd11655.zip
chromium_src-fdb4c7db1703189d9d26526e12c03cab7dd11655.tar.gz
chromium_src-fdb4c7db1703189d9d26526e12c03cab7dd11655.tar.bz2
Rolling back r34316 due to tab_switching_test failing. TBR=scherkus
TEST=none BUG=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34374 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/browser_list.cc7
-rw-r--r--chrome/browser/browser_shutdown.cc6
-rw-r--r--chrome/browser/extensions/extension_process_manager.cc16
3 files changed, 2 insertions, 27 deletions
diff --git a/chrome/browser/browser_list.cc b/chrome/browser/browser_list.cc
index 7f7b753..413fda9 100644
--- a/chrome/browser/browser_list.cc
+++ b/chrome/browser/browser_list.cc
@@ -151,12 +151,7 @@ void BrowserList::AddBrowser(Browser* browser) {
void BrowserList::RemoveBrowser(Browser* browser) {
RemoveBrowserFrom(browser, &last_active_browsers_);
- bool close_app = false;
- // Since closing all windows does not indicate quitting the application on
- // Mac, don't check the condition based on the number of browser windows.
-#if defined(OS_WIN) || defined(OS_LINUX)
- close_app = (browsers_.size() == 1);
-#endif
+ bool close_app = (browsers_.size() == 1);
NotificationService::current()->Notify(
NotificationType::BROWSER_CLOSED,
Source<Browser>(browser), Details<bool>(&close_app));
diff --git a/chrome/browser/browser_shutdown.cc b/chrome/browser/browser_shutdown.cc
index 3062dd7..520ead7 100644
--- a/chrome/browser/browser_shutdown.cc
+++ b/chrome/browser/browser_shutdown.cc
@@ -24,7 +24,6 @@
#include "chrome/browser/renderer_host/render_view_host.h"
#include "chrome/browser/renderer_host/render_widget_host.h"
#include "chrome/common/chrome_paths.h"
-#include "chrome/common/notification_service.h"
#include "chrome/common/pref_names.h"
#include "chrome/common/pref_service.h"
#include "chrome/common/chrome_plugin_lib.h"
@@ -91,11 +90,6 @@ FilePath GetShutdownMsPath() {
#endif
void Shutdown() {
-#if defined(OS_MACOSX)
- NotificationService::current()->Notify(NotificationType::APP_TERMINATING,
- NotificationService::AllSources(),
- NotificationService::NoDetails());
-#endif
// Unload plugins. This needs to happen on the IO thread.
ChromeThread::PostTask(
ChromeThread::IO, FROM_HERE,
diff --git a/chrome/browser/extensions/extension_process_manager.cc b/chrome/browser/extensions/extension_process_manager.cc
index 34b647b..78cd214 100644
--- a/chrome/browser/extensions/extension_process_manager.cc
+++ b/chrome/browser/extensions/extension_process_manager.cc
@@ -49,10 +49,6 @@ ExtensionProcessManager::ExtensionProcessManager(Profile* profile)
NotificationService::AllSources());
registrar_.Add(this, NotificationType::BROWSER_CLOSED,
NotificationService::AllSources());
-#if defined(OS_MACOSX)
- registrar_.Add(this, NotificationType::APP_TERMINATING,
- NotificationService::AllSources());
-#endif
}
ExtensionProcessManager::~ExtensionProcessManager() {
@@ -250,23 +246,13 @@ void ExtensionProcessManager::Observe(NotificationType type,
case NotificationType::BROWSER_CLOSED: {
// Close background hosts when the last browser is closed so that they
// have time to shutdown various objects on different threads. Our
- // destructor is called too late in the shutdown sequence. This will never
- // occur on Mac. See the APP_TERMINATING case below.
+ // destructor is called too late in the shutdown sequence.
bool app_closing = *Details<bool>(details).ptr();
if (app_closing)
CloseBackgroundHosts();
break;
}
-#if defined(OS_MACOSX)
- case NotificationType::APP_TERMINATING: {
- // This is a Mac-specific notification since app_closing will never be
- // true in the BROWSER_CLOSED case.
- CloseBackgroundHosts();
- break;
- }
-#endif
-
default:
NOTREACHED();
}