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

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 GURL src_root_url() const;
kinuko 2011/03/14 11:03:57 src_root_url() and get_root_url() are not single g
ericu 2011/03/15 02:43:11 Removed. After fixing a bug, there was only one c
40
41 void set_dest_origin_url(const GURL& url) {
42 dest_origin_url_ = url;
43 }
44
45 const GURL& dest_origin_url() const {
46 return dest_origin_url_;
47 }
48
49 GURL dest_root_url() const;
50
51 FileSystemType src_type() const {
52 return src_type_;
53 }
54
55 void set_src_type(FileSystemType src_type) {
56 src_type_ = src_type;
57 }
58
59 FileSystemType dest_type() const {
60 return dest_type_;
61 }
62
63 void set_dest_type(FileSystemType dest_type) {
64 dest_type_ = dest_type;
65 }
66
22 private: 67 private:
23 // This file_system_file_util_ is not "owned" by FileSystemOperationContext. 68 // This file_system_file_util_ is not "owned" by FileSystemOperationContext.
24 // It is supposed to be a pointer to a singleton. 69 // It is supposed to be a pointer to a singleton.
70 scoped_refptr<FileSystemContext> file_system_context_;
25 FileSystemFileUtil* file_system_file_util_; 71 FileSystemFileUtil* file_system_file_util_;
72
73 GURL src_origin_url_; // Also used for any single-path operation.
74 GURL dest_origin_url_;
75 FileSystemType src_type_; // Also used for any single-path operation.
76 FileSystemType dest_type_;
26 }; 77 };
27 78
28 } // namespace fileapi 79 } // namespace fileapi
29 80
30 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_ 81 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_CONTEXT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698