AIR NativeDragManager is BROKEN with IE 8
The AIR NativeDragManager is broken when interacting with IE 8 on any operating system. This is true in both AIR 1.5.x and the latest AIR 2 Beta 2.
The clipboard has null data when you drag and drop from IE 8. This does not happen with any other browser.
When you drag and drop links from any browser besides IE 8, the event.clipboard.formats has four formats, HTML_FORMAT, FILE_PROMISE_LIST_FORMAT, URL_FORMAT and TEXT_FORMAT. Getting the URL_FORMAT returns the expected url.
When you drag and drop the same links from IE 8, the clipboard.formats has two values, FILE_PROMISE_LIST_FORMAT and URL_FORMAT, but the promise list is empty and the url is null.
In AIR 1.5.x, there is no FILE_PROMISE_LIST_FORMAT (because that's a 10.1 feature), but the url is still null when coming from IE 8.
This is trivial to test.
addEventListener(NativeDragEvent.NATIVE_DRAG_ENTER, onNativeDragEnter);
private function onNativeDragEnter(event:NativeDragEvent):void
{
trace(event.clipboard.formats);
if (event.clipboard.hasFormat(ClipboardFormats.URL_FORMAT))
{
trace("url = " + event.clipboard.getData(ClipboardFormats.URL_FORMAT));
}
}
Then, go to any webpage in IE 8 and attempt to drag and drop url links from the html page on to AIR. If you go to the same page and drag the same links in any other browser, it works as expected.
The worst part is, this is a critical bug for a company that's been working on an AIR app for over a year because their AIR app is entirely based on this feature working. I just found out about this bug and, after thorough testing, have determined that the fate of this company is in the hands of the Adobe AIR team.
Help us Adobe AIR team. You're our only hope.
UPDATE
I've realized this issue is not just with AIR, it looks like Microsoft broke drag-and-drop with IE8. You can't even drag and drop links into text fields in notepad. A quick google search demonstrates the problem is widespread. Microsoft, you suck.
May 7th, 2010 at 6:45 am
I wonder…does it work with Silverlight? If so, it might be more than a bug.