summaryrefslogtreecommitdiffstats
path: root/chrome/browser/ui/browser_list.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/ui/browser_list.cc')
-rw-r--r--chrome/browser/ui/browser_list.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/chrome/browser/ui/browser_list.cc b/chrome/browser/ui/browser_list.cc
index ac7aa30..37b5425 100644
--- a/chrome/browser/ui/browser_list.cc
+++ b/chrome/browser/ui/browser_list.cc
@@ -700,6 +700,17 @@ bool BrowserList::IsOffTheRecordSessionActive() {
}
return false;
}
+// static
+bool BrowserList::IsOffTheRecordSessionActiveForProfile(Profile* profile) {
+ for (BrowserList::const_iterator i = BrowserList::begin();
+ i != BrowserList::end(); ++i) {
+ if ((*i)->profile()->IsSameProfile(profile) &&
+ (*i)->profile()->IsOffTheRecord()) {
+ return true;
+ }
+ }
+ return false;
+}
// static
void BrowserList::RemoveBrowserFrom(Browser* browser,