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

Unified Diff: webkit/fileapi/local_file_system_file_util.h

Issue 7174002: Change {Obfuscated|Local}FileSystemFileUtil non-Singleton to take an underlying *FileUtil. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Modified the comment. Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/fileapi/file_system_test_helper.cc ('k') | webkit/fileapi/local_file_system_file_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/fileapi/local_file_system_file_util.h
diff --git a/webkit/fileapi/local_file_system_file_util.h b/webkit/fileapi/local_file_system_file_util.h
index 8b18f68e4e8bfd0588d74c84cae5264b9d3239a3..dc31dc2422ef8e41865d43b8f521000b4eda57d8 100644
--- a/webkit/fileapi/local_file_system_file_util.h
+++ b/webkit/fileapi/local_file_system_file_util.h
@@ -13,7 +13,6 @@
#include "base/file_util_proxy.h"
#include "base/logging.h"
#include "base/memory/ref_counted.h"
kinuko 2011/07/05 06:35:24 nit: not necessary?
Dai Mikurube (NOT FULLTIME) 2011/07/05 08:05:40 Done.
-#include "base/memory/singleton.h"
#include "base/platform_file.h"
#include "base/tracked_objects.h"
kinuko 2011/07/05 06:35:24 nit: not necessary?
Dai Mikurube (NOT FULLTIME) 2011/07/05 08:05:40 Done.
#include "webkit/fileapi/file_system_file_util.h"
@@ -34,9 +33,12 @@ using base::PlatformFileError;
class FileSystemOperationContext;
+// Now, this class is created and owned only by *MountPointProvider and tests.
kinuko 2011/07/05 06:35:24 wording nit: 'Now, ' and 'only' is not needed I th
Dai Mikurube (NOT FULLTIME) 2011/07/05 08:05:40 Done.
class LocalFileSystemFileUtil : public FileSystemFileUtil {
public:
- static LocalFileSystemFileUtil* GetInstance();
+ // |underlying_file_util| is not owned by the instance. It will need to be
+ // a singleton or to be deleted by someone else.
+ explicit LocalFileSystemFileUtil(FileSystemFileUtil* underlying_file_util);
virtual PlatformFileError CreateOrOpen(
FileSystemOperationContext* context,
@@ -118,9 +120,6 @@ class LocalFileSystemFileUtil : public FileSystemFileUtil {
const FilePath& root_path);
protected:
- LocalFileSystemFileUtil() { }
-
- friend struct DefaultSingletonTraits<LocalFileSystemFileUtil>;
DISALLOW_COPY_AND_ASSIGN(LocalFileSystemFileUtil);
kinuko 2011/07/05 06:35:24 nit: why is this placed here? can we move this in
Dai Mikurube (NOT FULLTIME) 2011/07/05 08:05:40 Done.
private:
@@ -131,6 +130,8 @@ class LocalFileSystemFileUtil : public FileSystemFileUtil {
const GURL& origin_url,
FileSystemType type,
const FilePath& virtual_path);
+
+ FileSystemFileUtil* underlying_file_util_;
};
} // namespace fileapi
« no previous file with comments | « webkit/fileapi/file_system_test_helper.cc ('k') | webkit/fileapi/local_file_system_file_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698