summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser_list.h
diff options
context:
space:
mode:
authorsky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-05 22:43:22 +0000
committersky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-05 22:43:22 +0000
commit018cf36471451716c1fa14b99d7b2bbf780c883d (patch)
tree01d653cd9e00fe935039517c5504550d3d68ef8d /chrome/browser/browser_list.h
parentd911f1b926178d0642e0bb07bb42c6623d1bbf73 (diff)
downloadchromium_src-018cf36471451716c1fa14b99d7b2bbf780c883d.zip
chromium_src-018cf36471451716c1fa14b99d7b2bbf780c883d.tar.gz
chromium_src-018cf36471451716c1fa14b99d7b2bbf780c883d.tar.bz2
Second attempt at fix for Browser::AddTabWithURL. My first fix fixed
the crash, but I don't think it was really what you were after. I believe this is it. I've changed various places in Browser to use CanSupportWindowFeature rather than SupportsWindowFeature. This gives us the old behavior while allowing app windows to have tabs, which I believe is what you wanted. BUG=42914 TEST=see bug Review URL: http://codereview.chromium.org/1932005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46510 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_list.h')
-rw-r--r--chrome/browser/browser_list.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/chrome/browser/browser_list.h b/chrome/browser/browser_list.h
index 8038baf..a6113a7 100644
--- a/chrome/browser/browser_list.h
+++ b/chrome/browser/browser_list.h
@@ -72,6 +72,14 @@ class BrowserList {
static Browser* FindBrowserWithType(Profile* p, Browser::Type t,
bool match_incognito);
+ // Find an existing browser window that can provide the specified type (this
+ // uses Browser::CanSupportsWindowFeature, not
+ // Browser::SupportsWindowFeature). This searches in the order of last
+ // activation. Only browsers that have been active can be returned. Returns
+ // NULL if no such browser currently exists.
+ static Browser* FindBrowserWithFeature(Profile* p,
+ Browser::WindowFeature feature);
+
// Find an existing browser window with the provided profile. Searches in the
// order of last activation. Only browsers that have been active can be
// returned. Returns NULL if no such browser currently exists.