Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Unified Diff: headless/lib/browser/headless_browser_context.h

Issue 2043603004: headless: Introduce a browser context (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address nits Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « headless/app/headless_shell.cc ('k') | headless/lib/browser/headless_browser_context.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: headless/lib/browser/headless_browser_context.h
diff --git a/headless/lib/browser/headless_browser_context.h b/headless/lib/browser/headless_browser_context.h
deleted file mode 100644
index 91bff6525f8dc400c487f05f857aac27e7c80a4b..0000000000000000000000000000000000000000
--- a/headless/lib/browser/headless_browser_context.h
+++ /dev/null
@@ -1,68 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_CONTEXT_H_
-#define HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_CONTEXT_H_
-
-#include <memory>
-
-#include "base/files/file_path.h"
-#include "content/public/browser/browser_context.h"
-#include "content/public/browser/content_browser_client.h"
-#include "content/public/browser/resource_context.h"
-#include "headless/lib/browser/headless_url_request_context_getter.h"
-#include "headless/public/headless_browser.h"
-
-namespace headless {
-class HeadlessResourceContext;
-
-class HeadlessBrowserContext : public content::BrowserContext {
- public:
- explicit HeadlessBrowserContext(HeadlessBrowser::Options* options);
- ~HeadlessBrowserContext() override;
-
- // BrowserContext implementation:
- std::unique_ptr<content::ZoomLevelDelegate> CreateZoomLevelDelegate(
- const base::FilePath& partition_path) override;
- base::FilePath GetPath() const override;
- bool IsOffTheRecord() const override;
- content::ResourceContext* GetResourceContext() override;
- content::DownloadManagerDelegate* GetDownloadManagerDelegate() override;
- content::BrowserPluginGuestManager* GetGuestManager() override;
- storage::SpecialStoragePolicy* GetSpecialStoragePolicy() override;
- content::PushMessagingService* GetPushMessagingService() override;
- content::SSLHostStateDelegate* GetSSLHostStateDelegate() override;
- content::PermissionManager* GetPermissionManager() override;
- content::BackgroundSyncController* GetBackgroundSyncController() override;
- net::URLRequestContextGetter* CreateRequestContext(
- content::ProtocolHandlerMap* protocol_handlers,
- content::URLRequestInterceptorScopedVector request_interceptors) override;
- net::URLRequestContextGetter* CreateRequestContextForStoragePartition(
- const base::FilePath& partition_path,
- bool in_memory,
- content::ProtocolHandlerMap* protocol_handlers,
- content::URLRequestInterceptorScopedVector request_interceptors) override;
- net::URLRequestContextGetter* CreateMediaRequestContext() override;
- net::URLRequestContextGetter* CreateMediaRequestContextForStoragePartition(
- const base::FilePath& partition_path,
- bool in_memory) override;
-
- HeadlessBrowser::Options* options() const { return options_; }
- void SetOptionsForTesting(HeadlessBrowser::Options* options);
-
- private:
- // Performs initialization of the HeadlessBrowserContext while IO is still
- // allowed on the current thread.
- void InitWhileIOAllowed();
-
- base::FilePath path_;
- std::unique_ptr<HeadlessResourceContext> resource_context_;
- HeadlessBrowser::Options* options_; // Not owned.
-
- DISALLOW_COPY_AND_ASSIGN(HeadlessBrowserContext);
-};
-
-} // namespace headless
-
-#endif // HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_CONTEXT_H_
« no previous file with comments | « headless/app/headless_shell.cc ('k') | headless/lib/browser/headless_browser_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698