Index: Source/core/fileapi/File.cpp |
diff --git a/Source/core/fileapi/File.cpp b/Source/core/fileapi/File.cpp |
index 3297989c4bdd6b47869f2778b19502308d895d66..6a2a1918d9a5ee39cbe52d8536d7ad04a9f72cf0 100644 |
--- a/Source/core/fileapi/File.cpp |
+++ b/Source/core/fileapi/File.cpp |
@@ -159,6 +159,27 @@ File::File(const KURL& fileSystemURL, const FileMetadata& metadata) |
{ |
} |
+File::File(const File& other) |
+ : Blob(other.blobDataHandle()) |
+ , m_hasBackingFile(other.m_hasBackingFile) |
+ , m_userVisibility(other.m_userVisibility) |
+ , m_path(other.m_path) |
+ , m_name(other.m_name) |
+ , m_fileSystemURL(other.m_fileSystemURL) |
+ , m_snapshotSize(other.m_snapshotSize) |
+ , m_snapshotModificationTime(other.m_snapshotModificationTime) |
+ , m_relativePath(other.m_relativePath) |
+{ |
+} |
+ |
+PassRefPtrWillBeRawPtr<File> File::clone(const String& name) const |
+{ |
+ RefPtrWillBeRawPtr<File> file = adoptRefWillBeNoop(new File(*this)); |
+ if (!name.isNull()) |
+ file->m_name = name; |
+ return file.release(); |
+} |
+ |
double File::lastModifiedMS() const |
{ |
if (hasValidSnapshotMetadata() && isValidFileTime(m_snapshotModificationTime)) |