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

Unified Diff: chrome/browser/automation/automation_provider_observers.cc

Issue 10800031: Remove details from BROWSER_CLOSING and BROWSER_CLOSED notifications. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed automation 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/profiles/profile_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/automation/automation_provider_observers.cc
diff --git a/chrome/browser/automation/automation_provider_observers.cc b/chrome/browser/automation/automation_provider_observers.cc
index d11f2e485c8f373e4760d7e166dc0c68ebdf7b93..d64b673ede2ee81ffee1c3ca56a8c130fd74e89b 100644
--- a/chrome/browser/automation/automation_provider_observers.cc
+++ b/chrome/browser/automation/automation_provider_observers.cc
@@ -878,7 +878,9 @@ void BrowserClosedNotificationObserver::Observe(
return;
}
- content::Details<bool> close_app(details);
+ int browser_count = static_cast<int>(BrowserList::size());
+ // We get the notification before the browser is removed from the BrowserList.
+ bool app_closing = browser_count == 1;
if (use_json_interface_) {
AutomationJSONReply(automation_,
@@ -889,7 +891,7 @@ void BrowserClosedNotificationObserver::Observe(
true);
} else {
AutomationMsg_CloseBrowser::WriteReplyParams(reply_message_.get(), true,
- *(close_app.ptr()));
+ app_closing);
}
automation_->Send(reply_message_.release());
}
« no previous file with comments | « no previous file | chrome/browser/profiles/profile_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698