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

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

Issue 6338002: net: Remove typedef net::URLRequestContext URLRequestContext; (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: for real Created 9 years, 11 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/sandboxed_file_system_operation.h" 5 #include "webkit/fileapi/sandboxed_file_system_operation.h"
6 6
7 #include "net/url_request/url_request_context.h" 7 #include "net/url_request/url_request_context.h"
8 #include "webkit/fileapi/file_system_callback_dispatcher.h" 8 #include "webkit/fileapi/file_system_callback_dispatcher.h"
9 #include "webkit/fileapi/file_system_path_manager.h" 9 #include "webkit/fileapi/file_system_path_manager.h"
10 #include "webkit/fileapi/file_system_quota_manager.h" 10 #include "webkit/fileapi/file_system_quota_manager.h"
11 #include "webkit/fileapi/sandboxed_file_system_context.h" 11 #include "webkit/fileapi/sandboxed_file_system_context.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 void SandboxedFileSystemOperation::Remove( 113 void SandboxedFileSystemOperation::Remove(
114 const FilePath& path, bool recursive) { 114 const FilePath& path, bool recursive) {
115 if (!VerifyFileSystemPathForWrite(path, false /* create */, 0)) { 115 if (!VerifyFileSystemPathForWrite(path, false /* create */, 0)) {
116 delete this; 116 delete this;
117 return; 117 return;
118 } 118 }
119 FileSystemOperation::Remove(path, recursive); 119 FileSystemOperation::Remove(path, recursive);
120 } 120 }
121 121
122 void SandboxedFileSystemOperation::Write( 122 void SandboxedFileSystemOperation::Write(
123 scoped_refptr<URLRequestContext> url_request_context, 123 scoped_refptr<net::URLRequestContext> url_request_context,
124 const FilePath& path, const GURL& blob_url, int64 offset) { 124 const FilePath& path, const GURL& blob_url, int64 offset) {
125 if (!VerifyFileSystemPathForWrite(path, true /* create */, 125 if (!VerifyFileSystemPathForWrite(path, true /* create */,
126 FileSystemQuotaManager::kUnknownSize)) { 126 FileSystemQuotaManager::kUnknownSize)) {
127 delete this; 127 delete this;
128 return; 128 return;
129 } 129 }
130 FileSystemOperation::Write(url_request_context, path, blob_url, offset); 130 FileSystemOperation::Write(url_request_context, path, blob_url, offset);
131 } 131 }
132 132
133 void SandboxedFileSystemOperation::Truncate( 133 void SandboxedFileSystemOperation::Truncate(
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 // need to resolve what amount of size it's going to write. 193 // need to resolve what amount of size it's going to write.
194 if (!file_system_context_->quota_manager()->CheckOriginQuota( 194 if (!file_system_context_->quota_manager()->CheckOriginQuota(
195 origin_url, growth)) { 195 origin_url, growth)) {
196 dispatcher()->DidFail(base::PLATFORM_FILE_ERROR_NO_SPACE); 196 dispatcher()->DidFail(base::PLATFORM_FILE_ERROR_NO_SPACE);
197 return false; 197 return false;
198 } 198 }
199 return true; 199 return true;
200 } 200 }
201 201
202 } // namespace fileapi 202 } // namespace fileapi
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698