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

Unified Diff: android_webview/lib/aw_browser_dependency_factory_impl.h

Issue 10913074: Add WebView implementation for CookieManager. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebased Created 8 years, 3 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
Index: android_webview/lib/aw_browser_dependency_factory_impl.h
diff --git a/android_webview/lib/aw_browser_dependency_factory_impl.h b/android_webview/lib/aw_browser_dependency_factory_impl.h
index fae835f31032b2991001ab9c4e7aae0fd1ee2c1e..4b9a00371d823a9e0ca1c00239d9d999a23391e6 100644
--- a/android_webview/lib/aw_browser_dependency_factory_impl.h
+++ b/android_webview/lib/aw_browser_dependency_factory_impl.h
@@ -8,9 +8,16 @@
#include "android_webview/native/aw_browser_dependency_factory.h"
#include "base/compiler_specific.h"
+#include "base/memory/scoped_ptr.h"
+
+namespace net {
+class URLRequestContextGetter;
+}
namespace android_webview {
+class AwNetworkDelegate;
+
class AwBrowserDependencyFactoryImpl : public AwBrowserDependencyFactory {
public:
AwBrowserDependencyFactoryImpl();
@@ -20,6 +27,7 @@ class AwBrowserDependencyFactoryImpl : public AwBrowserDependencyFactory {
static void InstallInstance();
// AwBrowserDependencyFactory
+ virtual content::BrowserContext* GetBrowserContext(bool incognito) OVERRIDE;
virtual content::WebContents* CreateWebContents(bool incognito) OVERRIDE;
virtual AwContentsContainer* CreateContentsContainer(
content::WebContents* contents) OVERRIDE;
@@ -27,6 +35,16 @@ class AwBrowserDependencyFactoryImpl : public AwBrowserDependencyFactory {
OVERRIDE;
private:
+ void InitializeNetworkDelegateOnIOThread(
+ net::URLRequestContextGetter* normal_context,
+ net::URLRequestContextGetter* incognito_context);
+ void EnsureNetworkDelegateInitialized();
+
+ // Constructed and assigned on the IO thread.
+ scoped_ptr<AwNetworkDelegate> network_delegate_;
+ // Set on the UI thread.
+ bool initialized_network_delegate_;
+
DISALLOW_COPY_AND_ASSIGN(AwBrowserDependencyFactoryImpl);
};

Powered by Google App Engine
This is Rietveld 408576698