OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2008, 2009, Google Inc. All rights reserved. | 2 * Copyright (c) 2008, 2009, 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 18 matching lines...) Expand all Loading... |
29 */ | 29 */ |
30 | 30 |
31 #ifndef DataObject_h | 31 #ifndef DataObject_h |
32 #define DataObject_h | 32 #define DataObject_h |
33 | 33 |
34 #include "core/CoreExport.h" | 34 #include "core/CoreExport.h" |
35 #include "core/clipboard/DataObjectItem.h" | 35 #include "core/clipboard/DataObjectItem.h" |
36 #include "platform/PasteMode.h" | 36 #include "platform/PasteMode.h" |
37 #include "platform/Supplementable.h" | 37 #include "platform/Supplementable.h" |
38 #include "platform/heap/Handle.h" | 38 #include "platform/heap/Handle.h" |
39 #include "wtf/ListHashSet.h" | |
40 #include "wtf/PassRefPtr.h" | 39 #include "wtf/PassRefPtr.h" |
41 #include "wtf/Vector.h" | 40 #include "wtf/Vector.h" |
42 #include "wtf/text/StringHash.h" | 41 #include "wtf/text/StringHash.h" |
43 #include "wtf/text/WTFString.h" | 42 #include "wtf/text/WTFString.h" |
44 | 43 |
45 namespace blink { | 44 namespace blink { |
46 | 45 |
47 class KURL; | 46 class KURL; |
48 class SharedBuffer; | 47 class SharedBuffer; |
49 class WebDragData; | 48 class WebDragData; |
(...skipping 16 matching lines...) Expand all Loading... |
66 // FIXME: Implement V8DataTransferItemList::indexedPropertyDeleter to get th
is called. | 65 // FIXME: Implement V8DataTransferItemList::indexedPropertyDeleter to get th
is called. |
67 void deleteItem(unsigned long index); | 66 void deleteItem(unsigned long index); |
68 void clearAll(); | 67 void clearAll(); |
69 // Returns null if an item already exists with the provided type. | 68 // Returns null if an item already exists with the provided type. |
70 DataObjectItem* add(const String& data, const String& type); | 69 DataObjectItem* add(const String& data, const String& type); |
71 DataObjectItem* add(File*); | 70 DataObjectItem* add(File*); |
72 | 71 |
73 // WebCore helpers. | 72 // WebCore helpers. |
74 void clearData(const String& type); | 73 void clearData(const String& type); |
75 | 74 |
76 ListHashSet<String> types() const; | 75 Vector<String> types() const; |
77 String getData(const String& type) const; | 76 String getData(const String& type) const; |
78 void setData(const String& type, const String& data); | 77 void setData(const String& type, const String& data); |
79 | 78 |
80 void urlAndTitle(String& url, String* title = 0) const; | 79 void urlAndTitle(String& url, String* title = 0) const; |
81 void setURLAndTitle(const String& url, const String& title); | 80 void setURLAndTitle(const String& url, const String& title); |
82 void htmlAndBaseURL(String& html, KURL& baseURL) const; | 81 void htmlAndBaseURL(String& html, KURL& baseURL) const; |
83 void setHTMLAndBaseURL(const String& html, const KURL& baseURL); | 82 void setHTMLAndBaseURL(const String& html, const KURL& baseURL); |
84 | 83 |
85 // Used for dragging in files from the desktop. | 84 // Used for dragging in files from the desktop. |
86 bool containsFilenames() const; | 85 bool containsFilenames() const; |
(...skipping 24 matching lines...) Expand all Loading... |
111 HeapVector<Member<DataObjectItem>> m_itemList; | 110 HeapVector<Member<DataObjectItem>> m_itemList; |
112 | 111 |
113 // State of Shift/Ctrl/Alt/Meta keys and Left/Right/Middle mouse buttons | 112 // State of Shift/Ctrl/Alt/Meta keys and Left/Right/Middle mouse buttons |
114 int m_modifiers; | 113 int m_modifiers; |
115 String m_filesystemId; | 114 String m_filesystemId; |
116 }; | 115 }; |
117 | 116 |
118 } // namespace blink | 117 } // namespace blink |
119 | 118 |
120 #endif | 119 #endif |
OLD | NEW |