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

Side by Side Diff: webkit/fileapi/file_system_operation_context.h

Issue 6603034: Stop returning the true root path of each filesystem from openFileSystem.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 9 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) 2011 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 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_ 5 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_
6 #define WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_ 6 #define WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_
7 7
8 #include "base/ref_counted.h"
9 #include "googleurl/src/gurl.h"
8 #include "webkit/fileapi/file_system_file_util.h" 10 #include "webkit/fileapi/file_system_file_util.h"
11 #include "webkit/fileapi/file_system_types.h"
9 12
10 namespace fileapi { 13 namespace fileapi {
11 14
15 class FileSystemContext;
16
12 class FileSystemOperationContext { 17 class FileSystemOperationContext {
13 public: 18 public:
14 FileSystemOperationContext(FileSystemFileUtil* file_system_file_util) 19 FileSystemOperationContext(
15 : file_system_file_util_(file_system_file_util) { 20 FileSystemContext* context,
21 FileSystemFileUtil* file_system_file_util);
22
23 FileSystemContext* file_system_context() const {
24 return file_system_context_.get();
16 } 25 }
17 26
18 FileSystemFileUtil* file_system_file_util() const { 27 FileSystemFileUtil* file_system_file_util() const {
19 return file_system_file_util_; 28 return file_system_file_util_;
20 } 29 }
21 30
31 void set_src_origin_url(const GURL& url) {
32 src_origin_url_ = url;
33 }
34
35 const GURL& src_origin_url() const {
36 return src_origin_url_;
37 }
38
39 void set_dest_origin_url(const GURL& url) {
40 dest_origin_url_ = url;
41 }
42
43 const GURL& dest_origin_url() const {
44 return dest_origin_url_;
45 }
46
47 FileSystemType src_type() const {
48 return src_type_;
49 }
50
51 void set_src_type(FileSystemType src_type) {
52 src_type_ = src_type;
53 }
54
55 FileSystemType dest_type() const {
56 return dest_type_;
57 }
58
59 void set_dest_type(FileSystemType dest_type) {
60 dest_type_ = dest_type;
61 }
62
22 private: 63 private:
23 // This file_system_file_util_ is not "owned" by FileSystemOperationContext. 64 // This file_system_file_util_ is not "owned" by FileSystemOperationContext.
24 // It is supposed to be a pointer to a singleton. 65 // It is supposed to be a pointer to a singleton.
66 scoped_refptr<FileSystemContext> file_system_context_;
25 FileSystemFileUtil* file_system_file_util_; 67 FileSystemFileUtil* file_system_file_util_;
68
69 GURL src_origin_url_; // Also used for any single-path operation.
70 GURL dest_origin_url_;
71 FileSystemType src_type_; // Also used for any single-path operation.
72 FileSystemType dest_type_;
26 }; 73 };
27 74
28 } // namespace fileapi 75 } // namespace fileapi
29 76
30 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_ 77 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_
OLDNEW
« no previous file with comments | « webkit/fileapi/file_system_operation.cc ('k') | webkit/fileapi/file_system_operation_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698