| 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 26 matching lines...) Expand all Loading... |
| 37 #include "platform/weborigin/KURL.h" | 37 #include "platform/weborigin/KURL.h" |
| 38 #include "wtf/RefCounted.h" | 38 #include "wtf/RefCounted.h" |
| 39 #include "wtf/RefPtr.h" | 39 #include "wtf/RefPtr.h" |
| 40 #include "wtf/text/WTFString.h" | 40 #include "wtf/text/WTFString.h" |
| 41 | 41 |
| 42 namespace WebCore { | 42 namespace WebCore { |
| 43 | 43 |
| 44 class Blob; | 44 class Blob; |
| 45 | 45 |
| 46 class DataObjectItem : public RefCountedWillBeGarbageCollectedFinalized<DataObje
ctItem> { | 46 class DataObjectItem : public RefCountedWillBeGarbageCollectedFinalized<DataObje
ctItem> { |
| 47 DECLARE_GC_INFO; | |
| 48 public: | 47 public: |
| 49 enum Kind { | 48 enum Kind { |
| 50 StringKind, | 49 StringKind, |
| 51 FileKind | 50 FileKind |
| 52 }; | 51 }; |
| 53 | 52 |
| 54 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromString(const String&
type, const String& data); | 53 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromString(const String&
type, const String& data); |
| 55 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromFile(PassRefPtr<File
>); | 54 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromFile(PassRefPtr<File
>); |
| 56 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromURL(const String& ur
l, const String& title); | 55 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromURL(const String& ur
l, const String& title); |
| 57 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromHTML(const String& h
tml, const KURL& baseURL); | 56 static PassRefPtrWillBeRawPtr<DataObjectItem> createFromHTML(const String& h
tml, const KURL& baseURL); |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 // Optional metadata. Currently used for URL, HTML, and dragging files in. | 89 // Optional metadata. Currently used for URL, HTML, and dragging files in. |
| 91 String m_title; | 90 String m_title; |
| 92 KURL m_baseURL; | 91 KURL m_baseURL; |
| 93 | 92 |
| 94 uint64_t m_sequenceNumber; // Only valid when m_source == PasteboardSource | 93 uint64_t m_sequenceNumber; // Only valid when m_source == PasteboardSource |
| 95 }; | 94 }; |
| 96 | 95 |
| 97 } // namespace WebCore | 96 } // namespace WebCore |
| 98 | 97 |
| 99 #endif // DataObjectItem_h | 98 #endif // DataObjectItem_h |
| OLD | NEW |