summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_list.h
diff options
context:
space:
mode:
authorphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-13 07:07:18 +0000
committerphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-13 07:07:18 +0000
commit42599f8282ae724f2aec50ff4ac91bebbc0451e6 (patch)
tree47b890c20f519b5800cb093c38dd5c4a867c07bd /chrome/browser/browser_list.h
parent5f794c15856aaa57b8b84f3bb89f2f744447ed23 (diff)
downloadchromium_src-42599f8282ae724f2aec50ff4ac91bebbc0451e6.zip
chromium_src-42599f8282ae724f2aec50ff4ac91bebbc0451e6.tar.gz
chromium_src-42599f8282ae724f2aec50ff4ac91bebbc0451e6.tar.bz2
Make sure the download status in the application icon is updated
when an incognito window is closed. This also avoids crash described in http://code.google.com/p/chromium/issues/detail?id=56722#c12 We need to remove the half-destroyed Browser from BrowserList before we start iterating over BrowserList when updating the application icon. BUG=48391 TEST=see bug Review URL: http://codereview.chromium.org/3719004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62377 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_list.h')
-rw-r--r--chrome/browser/browser_list.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/chrome/browser/browser_list.h b/chrome/browser/browser_list.h
index dcde7fb..0d680ae 100644
--- a/chrome/browser/browser_list.h
+++ b/chrome/browser/browser_list.h
@@ -26,8 +26,8 @@ class BrowserList {
// Called immediately after a browser is added to the list
virtual void OnBrowserAdded(const Browser* browser) = 0;
- // Called immediately before a browser is removed from the list
- virtual void OnBrowserRemoving(const Browser* browser) = 0;
+ // Called immediately after a browser is removed from the list
+ virtual void OnBrowserRemoved(const Browser* browser) = 0;
// Called immediately after a browser is set active (SetLastActive)
virtual void OnBrowserSetLastActive(const Browser* browser) {}
@@ -130,6 +130,7 @@ class BrowserList {
static const_iterator begin() { return browsers_.begin(); }
static const_iterator end() { return browsers_.end(); }
+ static bool empty() { return browsers_.empty(); }
static size_t size() { return browsers_.size(); }
// Returns iterated access to list of open browsers ordered by when