Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 Loading... | |
| 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 DataTransferItemList_h | 31 #ifndef DataTransferItemList_h |
| 32 #define DataTransferItemList_h | 32 #define DataTransferItemList_h |
| 33 | 33 |
| 34 #include "bindings/v8/ScriptWrappable.h" | 34 #include "bindings/v8/ScriptWrappable.h" |
| 35 #include "heap/Handle.h" | |
| 35 #include "wtf/Forward.h" | 36 #include "wtf/Forward.h" |
| 36 #include "wtf/RefCounted.h" | 37 #include "wtf/RefCounted.h" |
| 37 #include "wtf/RefPtr.h" | 38 #include "wtf/RefPtr.h" |
| 38 | 39 |
| 39 namespace WebCore { | 40 namespace WebCore { |
| 40 | 41 |
| 41 class DataObject; | 42 class DataObject; |
| 42 class Clipboard; | 43 class Clipboard; |
| 43 class DataTransferItem; | 44 class DataTransferItem; |
| 44 class File; | 45 class File; |
| 45 | 46 |
| 46 class ExceptionState; | 47 class ExceptionState; |
| 47 | 48 |
| 48 class DataTransferItemList : public RefCounted<DataTransferItemList>, public Scr iptWrappable { | 49 class DataTransferItemList : public RefCountedWillBeGarbageCollected<DataTransfe rItemList>, public ScriptWrappable { |
|
zerny-chromium
2014/02/17 10:43:13
+Finalized
| |
| 50 DECLARE_GC_INFO; | |
| 49 public: | 51 public: |
| 50 static PassRefPtr<DataTransferItemList> create(PassRefPtr<Clipboard>, PassRe fPtr<DataObject>); | 52 static PassRefPtrWillBeRawPtr<DataTransferItemList> create(PassRefPtrWillBeR awPtr<Clipboard>, PassRefPtrWillBeRawPtr<DataObject>); |
| 51 ~DataTransferItemList(); | 53 ~DataTransferItemList(); |
| 52 | 54 |
| 53 size_t length() const; | 55 size_t length() const; |
| 54 PassRefPtr<DataTransferItem> item(unsigned long index); | 56 PassRefPtrWillBeRawPtr<DataTransferItem> item(unsigned long index); |
| 55 void deleteItem(unsigned long index, ExceptionState&); | 57 void deleteItem(unsigned long index, ExceptionState&); |
| 56 void clear(); | 58 void clear(); |
| 57 PassRefPtr<DataTransferItem> add(const String& data, const String& type, Exc eptionState&); | 59 PassRefPtrWillBeRawPtr<DataTransferItem> add(const String& data, const Strin g& type, ExceptionState&); |
| 58 PassRefPtr<DataTransferItem> add(PassRefPtr<File>); | 60 PassRefPtrWillBeRawPtr<DataTransferItem> add(PassRefPtr<File>); |
| 61 | |
| 62 void trace(Visitor*); | |
| 59 | 63 |
| 60 private: | 64 private: |
| 61 DataTransferItemList(PassRefPtr<Clipboard>, PassRefPtr<DataObject>); | 65 DataTransferItemList(PassRefPtrWillBeRawPtr<Clipboard>, PassRefPtrWillBeRawP tr<DataObject>); |
| 62 | 66 |
| 63 RefPtr<Clipboard> m_clipboard; | 67 RefPtrWillBeMember<Clipboard> m_clipboard; |
| 64 RefPtr<DataObject> m_dataObject; | 68 RefPtrWillBeMember<DataObject> m_dataObject; |
| 65 }; | 69 }; |
| 66 | 70 |
| 67 } // namespace WebCore | 71 } // namespace WebCore |
| 68 | 72 |
| 69 #endif // DataTransferItemList_h | 73 #endif // DataTransferItemList_h |
| OLD | NEW |