Package jreepad.ui

Examples of jreepad.ui.SaveFileChooser


        File saveLocation = document.getSaveLocation();
        if(askForFilename || saveLocation==null || (saveLocation.isFile() && !saveLocation.canWrite()))
        {
          // Ask for filename
          SaveFileChooser fileChooser = new SaveFileChooser(getPrefs().mainFileType);
          fileChooser.setCurrentDirectory(getPrefs().openLocation);

          fileChooser.setSelectedFile(new File(document.getRootNode().getTitle() +
                       (fileType==JreepadPrefs.FILETYPE_XML?".jree":".hjt")));
          if(fileChooser.showSaveDialog(JreepadViewer.this) != JFileChooser.APPROVE_OPTION)
          {
              successful = false;
              return; // No file chosen
          }
          saveLocation = fileChooser.getSelectedFile();
          fileType = fileChooser.getFileType();
        }
        getPrefs().openLocation = saveLocation; // Remember the file's directory

        // Save the file
        try
View Full Code Here

TOP

Related Classes of jreepad.ui.SaveFileChooser

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.