#include "chrome/browser/devtools/devtools_browser_context_manager.h"
#include "base/functional/bind.h"
#include "base/functional/callback_helpers.h"
#include "base/no_destructor.h"
#include "base/task/single_thread_task_runner.h"
#include "chrome/browser/profiles/profile_destroyer.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/browser_window.h"
namespace {
const int64_t kDestroyProfileTimeoutSeconds = …;
void DestroyOTRProfileWhenAppropriate(base::WeakPtr<Profile> weak_profile) { … }
}
DevToolsBrowserContextManager::DevToolsBrowserContextManager() { … }
DevToolsBrowserContextManager::~DevToolsBrowserContextManager() = default;
DevToolsBrowserContextManager& DevToolsBrowserContextManager::GetInstance() { … }
Profile* DevToolsBrowserContextManager::GetProfileById(
const std::string& context_id) { … }
content::BrowserContext* DevToolsBrowserContextManager::CreateBrowserContext() { … }
std::vector<content::BrowserContext*>
DevToolsBrowserContextManager::GetBrowserContexts() { … }
content::BrowserContext*
DevToolsBrowserContextManager::GetDefaultBrowserContext() { … }
void DevToolsBrowserContextManager::DisposeBrowserContext(
content::BrowserContext* context,
content::DevToolsManagerDelegate::DisposeCallback callback) { … }
void DevToolsBrowserContextManager::OnProfileWillBeDestroyed(Profile* profile) { … }
void DevToolsBrowserContextManager::OnBrowserRemoved(Browser* browser) { … }
void DevToolsBrowserContextManager::StopObservingProfileIfAny(
Profile* profile) { … }