Now that webkitGetAsEntry() has been activated on Chrome 21 to allow folder drag&drop, is there an equivalent in mozilla - mozGetAsEntry(), getAsEntry(), or something else? I've only been able to find very minimal info on webkit's method and the whatwg proposal; I can find nothing for Firefox (or any other browsers).
References:
What you're looking for is the mozGetDataAt()
method, which returns an nsIFile
object:
https://developer.mozilla.org/En/DragDrop/Recommended_Drag_Types#file
So to answer your question, the equivalent would be:
mozEntry = event.dataTransfer.mozGetDataAt(0);
or..
event.dataTransfer.mozGetDataAt(0).isFile()
etc.
Documentation for nsIFile
(contains the fields that are in the webkit entries):
https://developer.mozilla.org/en/XPCOM_Interface_Reference/nsIFile
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With