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

Unified Diff: content/browser/browser_context.cc

Issue 10907232: Make browser_context.cc compile for iOS (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Move char constants for cleaner ifdef-ing 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
« no previous file with comments | « no previous file | content/content_browser.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_context.cc
diff --git a/content/browser/browser_context.cc b/content/browser/browser_context.cc
index bae37b492a17d8a2a7ac8f0ff90079b0d8d6ddd1..cefaeded4aee24c9ac3857405bd2325fa450a5d9 100644
--- a/content/browser/browser_context.cc
+++ b/content/browser/browser_context.cc
@@ -4,6 +4,7 @@
#include "content/public/browser/browser_context.h"
+#if !defined(OS_IOS)
#include "content/browser/appcache/chrome_appcache_service.h"
#include "webkit/database/database_tracker.h"
#include "content/browser/dom_storage/dom_storage_context_impl.h"
@@ -24,17 +25,20 @@
#include "net/cookies/cookie_store.h"
#include "net/url_request/url_request_context.h"
#include "net/url_request/url_request_context_getter.h"
+#endif // !OS_IOS
using base::UserDataAdapter;
-// Key names on BrowserContext.
-static const char* kDownloadManagerKeyName = "download_manager";
-static const char* kStorageParitionMapKeyName = "content_storage_partition_map";
-
namespace content {
+// Only ~BrowserContext() is needed on iOS.
+#if !defined(OS_IOS)
namespace {
+// Key names on BrowserContext.
+const char* kDownloadManagerKeyName = "download_manager";
+const char* kStorageParitionMapKeyName = "content_storage_partition_map";
+
StoragePartition* GetStoragePartitionByPartitionId(
BrowserContext* browser_context,
const std::string& partition_id) {
@@ -219,10 +223,13 @@ void BrowserContext::PurgeMemory(BrowserContext* browser_context) {
ForEachStoragePartition(browser_context,
base::Bind(&PurgeDOMStorageContextInPartition));
}
+#endif // !OS_IOS
BrowserContext::~BrowserContext() {
+#if !defined(OS_IOS)
if (GetUserData(kDownloadManagerKeyName))
GetDownloadManager(this)->Shutdown();
+#endif
}
} // namespace content
« no previous file with comments | « no previous file | content/content_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698