#ifndef CHROME_BROWSER_UI_BROWSER_LIST_H_
#define CHROME_BROWSER_UI_BROWSER_LIST_H_
#include <vector>
#include "base/gtest_prod_util.h"
#include "ui/gfx/native_widget_types.h"
class Browser;
class Profile;
namespace browser {
class BrowserActivityObserver;
#if defined(OS_MACOSX)
Browser* GetLastActiveBrowser();
#endif
#if defined(TOOLKIT_GTK)
class ExtensionInstallDialog;
#endif
}
namespace chrome {
class BrowserListObserver;
namespace internal {
void NotifyNotDefaultBrowserCallback();
}
}
#if defined(OS_CHROMEOS)
namespace chromeos {
class ScreenLocker;
}
#endif
namespace content {
class WebContents;
}
namespace web_intents {
Browser* GetBrowserForBackgroundWebIntentDelivery(Profile*);
}
#if defined(USE_ASH)
content::WebContents* GetActiveWebContents();
#endif
class BrowserList {
public:
typedef std::vector<Browser*> BrowserVector;
typedef BrowserVector::iterator iterator;
typedef BrowserVector::const_iterator const_iterator;
typedef BrowserVector::const_reverse_iterator const_reverse_iterator;
static void AddBrowser(Browser* browser);
static void RemoveBrowser(Browser* browser);
static void AddObserver(chrome::BrowserListObserver* observer);
static void RemoveObserver(chrome::BrowserListObserver* observer);
static void SetLastActive(Browser* browser);
static void CloseAllBrowsersWithProfile(Profile* profile);
static const_iterator begin();
static const_iterator end();
static bool empty();
static size_t size();
static const_reverse_iterator begin_last_active();
static const_reverse_iterator end_last_active();
static bool IsOffTheRecordSessionActive();
static bool IsOffTheRecordSessionActiveForProfile(Profile* profile);
private:
friend class BrowserView;
friend class ChromeShellDelegate;
friend class NetworkProfileBubble;
friend class PrintPreviewHandler;
friend class SelectFileDialogExtension;
friend class StartupBrowserCreatorImpl;
friend class TaskManager;
friend class WindowSizer;
friend class browser::BrowserActivityObserver;
friend Browser* web_intents::GetBrowserForBackgroundWebIntentDelivery(
Profile*);
#if defined(OS_CHROMEOS)
friend class chromeos::ScreenLocker;
#endif
#if defined(OS_MACOSX)
friend Browser* browser::GetLastActiveBrowser();
#endif
#if defined(USE_ASH)
friend content::WebContents* GetActiveWebContents();
#endif
friend void chrome::internal::NotifyNotDefaultBrowserCallback();
static Browser* GetLastActive();
};
#endif