OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/storage_partition_impl.h" | 5 #include "content/browser/storage_partition_impl.h" |
6 | 6 |
7 #include "base/sequenced_task_runner.h" | 7 #include "base/sequenced_task_runner.h" |
8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" |
9 #include "content/browser/browser_main_loop.h" | 9 #include "content/browser/browser_main_loop.h" |
10 #include "content/browser/fileapi/browser_file_system_helper.h" | 10 #include "content/browser/fileapi/browser_file_system_helper.h" |
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 StoragePartitionImpl::~StoragePartitionImpl() { | 298 StoragePartitionImpl::~StoragePartitionImpl() { |
299 // These message loop checks are just to avoid leaks in unittests. | 299 // These message loop checks are just to avoid leaks in unittests. |
300 if (GetDatabaseTracker() && | 300 if (GetDatabaseTracker() && |
301 BrowserThread::IsMessageLoopValid(BrowserThread::FILE)) { | 301 BrowserThread::IsMessageLoopValid(BrowserThread::FILE)) { |
302 BrowserThread::PostTask( | 302 BrowserThread::PostTask( |
303 BrowserThread::FILE, FROM_HERE, | 303 BrowserThread::FILE, FROM_HERE, |
304 base::Bind(&webkit_database::DatabaseTracker::Shutdown, | 304 base::Bind(&webkit_database::DatabaseTracker::Shutdown, |
305 GetDatabaseTracker())); | 305 GetDatabaseTracker())); |
306 } | 306 } |
307 | 307 |
| 308 if (GetFileSystemContext()) |
| 309 GetFileSystemContext()->Shutdown(); |
| 310 |
308 if (GetDOMStorageContext()) | 311 if (GetDOMStorageContext()) |
309 GetDOMStorageContext()->Shutdown(); | 312 GetDOMStorageContext()->Shutdown(); |
310 } | 313 } |
311 | 314 |
312 // TODO(ajwong): Break the direct dependency on |context|. We only | 315 // TODO(ajwong): Break the direct dependency on |context|. We only |
313 // need 3 pieces of info from it. | 316 // need 3 pieces of info from it. |
314 StoragePartitionImpl* StoragePartitionImpl::Create( | 317 StoragePartitionImpl* StoragePartitionImpl::Create( |
315 BrowserContext* context, | 318 BrowserContext* context, |
316 bool in_memory, | 319 bool in_memory, |
317 const base::FilePath& partition_path) { | 320 const base::FilePath& partition_path) { |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
657 net::URLRequestContextGetter* url_request_context) { | 660 net::URLRequestContextGetter* url_request_context) { |
658 url_request_context_ = url_request_context; | 661 url_request_context_ = url_request_context; |
659 } | 662 } |
660 | 663 |
661 void StoragePartitionImpl::SetMediaURLRequestContext( | 664 void StoragePartitionImpl::SetMediaURLRequestContext( |
662 net::URLRequestContextGetter* media_url_request_context) { | 665 net::URLRequestContextGetter* media_url_request_context) { |
663 media_url_request_context_ = media_url_request_context; | 666 media_url_request_context_ = media_url_request_context; |
664 } | 667 } |
665 | 668 |
666 } // namespace content | 669 } // namespace content |
OLD | NEW |