This example shows how to drag data from other applications. Drag some text out of a text editor that allows it onto the text dropzone.

For files, Firefox and IE do not provide the DataTransferItem interface so we can't work out whether the image is actually of the type we want. We have to cancel the even and then check again on i'll show the drop whether the type matched.

Drop a png file on me.
Drop some text on to me. Or drag text out of me to another application, i'll show the selected operation on dragend. My default operation is to move text from the native application, if you press ctrl or alt on windows, i'll change to copy or link, the selected drop effect should effect what happens to the text in the native application.