Search in sources :

Example 1 with FileOpenService

use of javax.jnlp.FileOpenService in project javatari by ppeccin.

the class FileServiceROMChooser method chooseFileToLoad.

public static FileContents chooseFileToLoad() {
    try {
        FileOpenService fos = (FileOpenService) ServiceManager.lookup("javax.jnlp.FileOpenService");
        FileContents fileCon = fos.openFileDialog(null, ROMLoader.VALID_LOAD_FILE_EXTENSIONS);
        if (fileCon == null)
            return null;
        return fileCon;
    } catch (Exception ex) {
        System.out.println("File Service Cartridge Chooser: unable to open dialog\n" + ex);
        return null;
    }
}
Also used : FileContents(javax.jnlp.FileContents) FileOpenService(javax.jnlp.FileOpenService)

Aggregations

FileContents (javax.jnlp.FileContents)1 FileOpenService (javax.jnlp.FileOpenService)1