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

Side by Side Diff: third_party/WebKit/Source/modules/filesystem/FileWriterBase.h

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 14 matching lines...) Expand all
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #ifndef FileWriterBase_h 31 #ifndef FileWriterBase_h
32 #define FileWriterBase_h 32 #define FileWriterBase_h
33 33
34 #include "platform/heap/Handle.h" 34 #include "platform/heap/Handle.h"
35 #include "wtf/OwnPtr.h" 35 #include <memory>
36 #include "wtf/PassOwnPtr.h"
37 36
38 namespace blink { 37 namespace blink {
39 38
40 class WebFileWriter; 39 class WebFileWriter;
41 40
42 class FileWriterBase : public GarbageCollectedMixin { 41 class FileWriterBase : public GarbageCollectedMixin {
43 public: 42 public:
44 virtual ~FileWriterBase(); 43 virtual ~FileWriterBase();
45 void initialize(PassOwnPtr<WebFileWriter>, long long length); 44 void initialize(std::unique_ptr<WebFileWriter>, long long length);
46 45
47 long long position() const 46 long long position() const
48 { 47 {
49 return m_position; 48 return m_position;
50 } 49 }
51 long long length() const 50 long long length() const
52 { 51 {
53 return m_length; 52 return m_length;
54 } 53 }
55 54
(...skipping 13 matching lines...) Expand all
69 } 68 }
70 69
71 void setLength(long long length) 70 void setLength(long long length)
72 { 71 {
73 m_length = length; 72 m_length = length;
74 } 73 }
75 74
76 void seekInternal(long long position); 75 void seekInternal(long long position);
77 76
78 private: 77 private:
79 OwnPtr<WebFileWriter> m_writer; 78 std::unique_ptr<WebFileWriter> m_writer;
80 long long m_position; 79 long long m_position;
81 long long m_length; 80 long long m_length;
82 }; 81 };
83 82
84 } // namespace blink 83 } // namespace blink
85 84
86 #endif // FileWriterBase_h 85 #endif // FileWriterBase_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698