| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008, 2009 Google Inc. | 3 * Copyright (C) 2008, 2009 Google Inc. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 // Modified from DragDataWin.cpp to not directly call any windows methods as | 27 // Modified from DragDataWin.cpp to not directly call any windows methods as |
| 28 // they may not be available to us in the multiprocess | 28 // they may not be available to us in the multiprocess |
| 29 | 29 |
| 30 #include "config.h" | 30 #include "config.h" |
| 31 #include "DragData.h" | 31 #include "DragData.h" |
| 32 | 32 |
| 33 #include "ChromiumDataObject.h" | 33 #include "ChromiumDataObject.h" |
| 34 #include "ClipboardMimeTypes.h" | 34 #include "ClipboardMimeTypes.h" |
| 35 #include "Document.h" | 35 #include "Document.h" |
| 36 #include "DocumentFragment.h" | 36 #include "DocumentFragment.h" |
| 37 #include "DraggedIsolatedFileSystem.h" |
| 37 #include "FileSystem.h" | 38 #include "FileSystem.h" |
| 38 #include "Frame.h" | 39 #include "Frame.h" |
| 39 #include "KURL.h" | 40 #include "KURL.h" |
| 40 #include "NotImplemented.h" | 41 #include "NotImplemented.h" |
| 41 #include "markup.h" | 42 #include "markup.h" |
| 42 #include <wtf/text/WTFString.h> | 43 #include <wtf/text/WTFString.h> |
| 43 | 44 |
| 44 #include <public/Platform.h> | 45 #include <public/Platform.h> |
| 45 #include <public/WebFileUtilities.h> | 46 #include <public/WebFileUtilities.h> |
| 46 | 47 |
| 47 #if ENABLE(FILE_SYSTEM) | |
| 48 #include "DraggedIsolatedFileSystem.h" | |
| 49 #endif | |
| 50 | |
| 51 namespace WebCore { | 48 namespace WebCore { |
| 52 | 49 |
| 53 static bool containsHTML(const ChromiumDataObject* dropData) | 50 static bool containsHTML(const ChromiumDataObject* dropData) |
| 54 { | 51 { |
| 55 return dropData->types().contains(mimeTypeTextHTML); | 52 return dropData->types().contains(mimeTypeTextHTML); |
| 56 } | 53 } |
| 57 | 54 |
| 58 bool DragData::containsURL(Frame*, FilenameConversionPolicy filenamePolicy) cons
t | 55 bool DragData::containsURL(Frame*, FilenameConversionPolicy filenamePolicy) cons
t |
| 59 { | 56 { |
| 60 return m_platformDragData->types().contains(mimeTypeTextURIList) | 57 return m_platformDragData->types().contains(mimeTypeTextURIList) |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 | 157 |
| 161 return 0; | 158 return 0; |
| 162 } | 159 } |
| 163 | 160 |
| 164 Color DragData::asColor() const | 161 Color DragData::asColor() const |
| 165 { | 162 { |
| 166 notImplemented(); | 163 notImplemented(); |
| 167 return Color(); | 164 return Color(); |
| 168 } | 165 } |
| 169 | 166 |
| 170 #if ENABLE(FILE_SYSTEM) | |
| 171 String DragData::droppedFileSystemId() const | 167 String DragData::droppedFileSystemId() const |
| 172 { | 168 { |
| 173 DraggedIsolatedFileSystem* filesystem = DraggedIsolatedFileSystem::from(m_pl
atformDragData); | 169 DraggedIsolatedFileSystem* filesystem = DraggedIsolatedFileSystem::from(m_pl
atformDragData); |
| 174 if (!filesystem) | 170 if (!filesystem) |
| 175 return String(); | 171 return String(); |
| 176 return filesystem->filesystemId(); | 172 return filesystem->filesystemId(); |
| 177 } | 173 } |
| 178 #endif | |
| 179 | |
| 180 | 174 |
| 181 } // namespace WebCore | 175 } // namespace WebCore |
| OLD | NEW |