1

I'm trying to update a dashboard widget that has stopped working, I think with the upgrade to either Lion or Mountain Lion.

The widget has a drop zone for dropping files onto, which then uploads them to a web service.

However, my ondrop event handler is returning an empty string for the text/uri-list property of the dataTransfer object.

    types = event.dataTransfer.types;
    for (i=0; i < types.length; i++) alert(types[i]);

This reveals two potentially useful properties: text/uri-list and public.file-url.

However, calling getData on either always yields an empty string.

Does anyone know how to get the file URI for a file dropped onto a mac dashboard widget?

Thilina Chamath Hewagama
  • 9,039
  • 3
  • 32
  • 45
WoolyWonder
  • 171
  • 1
  • 6

0 Answers0