| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2001 Peter Kelly (pmk@post.com) | 2 * Copyright (C) 2001 Peter Kelly (pmk@post.com) |
| 3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de) | 3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de) |
| 4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2008 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2008 Apple Inc. All rights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 #include "wtf/RefCounted.h" | 33 #include "wtf/RefCounted.h" |
| 34 #include "wtf/RefPtr.h" | 34 #include "wtf/RefPtr.h" |
| 35 #include "wtf/Vector.h" | 35 #include "wtf/Vector.h" |
| 36 | 36 |
| 37 namespace WebCore { | 37 namespace WebCore { |
| 38 | 38 |
| 39 class ChromiumDataObject; | 39 class ChromiumDataObject; |
| 40 class DataTransferItemList; | 40 class DataTransferItemList; |
| 41 class DragImage; | 41 class DragImage; |
| 42 class Element; | 42 class Element; |
| 43 class ExceptionState; |
| 43 class FileList; | 44 class FileList; |
| 44 class Frame; | 45 class Frame; |
| 45 class ImageResource; | 46 class ImageResource; |
| 46 class Node; | 47 class Node; |
| 47 class Range; | 48 class Range; |
| 48 | 49 |
| 49 // State available during IE's events for drag and drop and copy/paste | 50 // State available during IE's events for drag and drop and copy/paste |
| 50 class Clipboard : public RefCounted<Clipboard>, public ScriptWrappable { | 51 class Clipboard : public RefCounted<Clipboard>, public ScriptWrappable { |
| 51 public: | 52 public: |
| 52 // Whether this clipboard is serving a drag-drop or copy-paste request. | 53 // Whether this clipboard is serving a drag-drop or copy-paste request. |
| (...skipping 16 matching lines...) Expand all Loading... |
| 69 | 70 |
| 70 void clearData(const String& type = String()); | 71 void clearData(const String& type = String()); |
| 71 String getData(const String& type) const; | 72 String getData(const String& type) const; |
| 72 bool setData(const String& type, const String& data); | 73 bool setData(const String& type, const String& data); |
| 73 | 74 |
| 74 // extensions beyond IE's API | 75 // extensions beyond IE's API |
| 75 Vector<String> types() const; | 76 Vector<String> types() const; |
| 76 PassRefPtr<FileList> files() const; | 77 PassRefPtr<FileList> files() const; |
| 77 | 78 |
| 78 IntPoint dragLocation() const { return m_dragLoc; } | 79 IntPoint dragLocation() const { return m_dragLoc; } |
| 79 ImageResource* dragImage() const { return m_dragImage.get(); } | 80 void setDragImage(Element*, int x, int y, ExceptionState&); |
| 80 void setDragImage(ImageResource*, const IntPoint&); | 81 ImageResource* dragImageResource() const { return m_dragImage.get(); } |
| 82 void setDragImageResource(ImageResource*, const IntPoint&); |
| 81 Node* dragImageElement() const { return m_dragImageElement.get(); } | 83 Node* dragImageElement() const { return m_dragImageElement.get(); } |
| 82 void setDragImageElement(Node*, const IntPoint&); | 84 void setDragImageElement(Node*, const IntPoint&); |
| 83 | 85 |
| 84 PassOwnPtr<DragImage> createDragImage(IntPoint& dragLocation, Frame*) const; | 86 PassOwnPtr<DragImage> createDragImage(IntPoint& dragLocation, Frame*) const; |
| 85 void declareAndWriteDragImage(Element*, const KURL&, const String& title); | 87 void declareAndWriteDragImage(Element*, const KURL&, const String& title); |
| 86 void writeURL(const KURL&, const String&); | 88 void writeURL(const KURL&, const String&); |
| 87 void writeRange(Range*, Frame*); | 89 void writeRange(Range*, Frame*); |
| 88 void writePlainText(const String&); | 90 void writePlainText(const String&); |
| 89 | 91 |
| 90 bool hasData(); | 92 bool hasData(); |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 ResourcePtr<ImageResource> m_dragImage; | 131 ResourcePtr<ImageResource> m_dragImage; |
| 130 RefPtr<Node> m_dragImageElement; | 132 RefPtr<Node> m_dragImageElement; |
| 131 }; | 133 }; |
| 132 | 134 |
| 133 DragOperation convertDropZoneOperationToDragOperation(const String& dragOperatio
n); | 135 DragOperation convertDropZoneOperationToDragOperation(const String& dragOperatio
n); |
| 134 String convertDragOperationToDropZoneOperation(DragOperation); | 136 String convertDragOperationToDropZoneOperation(DragOperation); |
| 135 | 137 |
| 136 } // namespace WebCore | 138 } // namespace WebCore |
| 137 | 139 |
| 138 #endif // Clipboard_h | 140 #endif // Clipboard_h |
| OLD | NEW |