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

Side by Side Diff: Source/core/fileapi/File.cpp

Issue 460393003: Cleanup namespace usage in Source/core/{dom/* & fileapi/*} (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix Error and Rebase Created 6 years, 4 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
« no previous file with comments | « Source/core/dom/VisitedLinkState.cpp ('k') | Source/core/fileapi/FileReaderLoader.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 RefPtrWillBeRawPtr<File> file = adoptRefWillBeNoop(new File(path, File::AllC ontentTypes, File::IsUserVisible)); 91 RefPtrWillBeRawPtr<File> file = adoptRefWillBeNoop(new File(path, File::AllC ontentTypes, File::IsUserVisible));
92 file->m_relativePath = relativePath; 92 file->m_relativePath = relativePath;
93 return file.release(); 93 return file.release();
94 } 94 }
95 95
96 File::File(const String& path, ContentTypeLookupPolicy policy, UserVisibility us erVisibility) 96 File::File(const String& path, ContentTypeLookupPolicy policy, UserVisibility us erVisibility)
97 : Blob(BlobDataHandle::create(createBlobDataForFile(path, policy), -1)) 97 : Blob(BlobDataHandle::create(createBlobDataForFile(path, policy), -1))
98 , m_hasBackingFile(true) 98 , m_hasBackingFile(true)
99 , m_userVisibility(userVisibility) 99 , m_userVisibility(userVisibility)
100 , m_path(path) 100 , m_path(path)
101 , m_name(blink::Platform::current()->fileUtilities()->baseName(path)) 101 , m_name(Platform::current()->fileUtilities()->baseName(path))
102 , m_snapshotSize(-1) 102 , m_snapshotSize(-1)
103 , m_snapshotModificationTime(invalidFileTime()) 103 , m_snapshotModificationTime(invalidFileTime())
104 { 104 {
105 ScriptWrappable::init(this); 105 ScriptWrappable::init(this);
106 } 106 }
107 107
108 File::File(const String& path, const String& name, ContentTypeLookupPolicy polic y, UserVisibility userVisibility) 108 File::File(const String& path, const String& name, ContentTypeLookupPolicy polic y, UserVisibility userVisibility)
109 : Blob(BlobDataHandle::create(createBlobDataForFileWithName(path, name, poli cy), -1)) 109 : Blob(BlobDataHandle::create(createBlobDataForFileWithName(path, name, poli cy), -1))
110 , m_hasBackingFile(true) 110 , m_hasBackingFile(true)
111 , m_userVisibility(userVisibility) 111 , m_userVisibility(userVisibility)
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 captureSnapshot(size, modificationTime); 296 captureSnapshot(size, modificationTime);
297 if (!m_fileSystemURL.isEmpty()) { 297 if (!m_fileSystemURL.isEmpty()) {
298 blobData.appendFileSystemURL(m_fileSystemURL, 0, size, modificationTime) ; 298 blobData.appendFileSystemURL(m_fileSystemURL, 0, size, modificationTime) ;
299 return; 299 return;
300 } 300 }
301 ASSERT(!m_path.isEmpty()); 301 ASSERT(!m_path.isEmpty());
302 blobData.appendFile(m_path, 0, size, modificationTime); 302 blobData.appendFile(m_path, 0, size, modificationTime);
303 } 303 }
304 304
305 } // namespace blink 305 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/dom/VisitedLinkState.cpp ('k') | Source/core/fileapi/FileReaderLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698