1

This post is related to on-boarding Java app in Mac App Store.

For accessing external files from a sandboxed Java app, I know there are restrictions like I have to use FileDialog instead of JFileChooser. Is there any restrictions on using Drag and Drop (DnD) functionality?

In my drop target listener code, I am using:

if (data.isDataFlavorSupported(DataFlavor.javaFileListFlavor)) {
    java.util.List<File> list = (java.util.List<File>) data.getTransferData(
        DataFlavor.javaFileListFlavor);
    for(File f: list) {
        // do my stuff!
    }
}

Will this code comply with Apple's sandbox restriction?

Subhash Chandran
  • 1,275
  • 1
  • 13
  • 20

0 Answers0