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

Side by Side Diff: webkit/fileapi/file_system_context.cc

Issue 9419033: Move creation of BrowserContext objects that live in content to content, instead of depending on th… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Fix memory leaks in tests Created 8 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "webkit/fileapi/file_system_context.h" 5 #include "webkit/fileapi/file_system_context.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "base/message_loop_proxy.h" 9 #include "base/message_loop_proxy.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 FileSystemContext::sandbox_provider() const { 134 FileSystemContext::sandbox_provider() const {
135 return sandbox_provider_.get(); 135 return sandbox_provider_.get();
136 } 136 }
137 137
138 ExternalFileSystemMountPointProvider* 138 ExternalFileSystemMountPointProvider*
139 FileSystemContext::external_provider() const { 139 FileSystemContext::external_provider() const {
140 return external_provider_.get(); 140 return external_provider_.get();
141 } 141 }
142 142
143 void FileSystemContext::DeleteOnCorrectThread() const { 143 void FileSystemContext::DeleteOnCorrectThread() const {
144 if (!io_message_loop_->BelongsToCurrentThread()) { 144 if (!io_message_loop_->BelongsToCurrentThread() &&
145 io_message_loop_->DeleteSoon(FROM_HERE, this); 145 io_message_loop_->DeleteSoon(FROM_HERE, this)) {
146 return; 146 return;
147 } 147 }
148 delete this; 148 delete this;
149 } 149 }
150 150
151 void FileSystemContext::OpenFileSystem( 151 void FileSystemContext::OpenFileSystem(
152 const GURL& origin_url, 152 const GURL& origin_url,
153 FileSystemType type, 153 FileSystemType type,
154 bool create, 154 bool create,
155 OpenFileSystemCallback callback) { 155 OpenFileSystemCallback callback) {
(...skipping 24 matching lines...) Expand all
180 return NULL; 180 return NULL;
181 FileSystemMountPointProvider* mount_point_provider = 181 FileSystemMountPointProvider* mount_point_provider =
182 GetMountPointProvider(file_system_type); 182 GetMountPointProvider(file_system_type);
183 if (!mount_point_provider) 183 if (!mount_point_provider)
184 return NULL; 184 return NULL;
185 return mount_point_provider->CreateFileSystemOperation( 185 return mount_point_provider->CreateFileSystemOperation(
186 origin_url, file_system_type, file_path, file_proxy, this); 186 origin_url, file_system_type, file_path, file_proxy, this);
187 } 187 }
188 188
189 } // namespace fileapi 189 } // namespace fileapi
OLDNEW
« no previous file with comments | « webkit/appcache/appcache_storage_impl.cc ('k') | webkit/fileapi/sandbox_mount_point_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698