@Override
public void saveState_actionPerformed(ActionEvent e)
{
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "jvp", "Jalview Project");
+ JalviewFileChooser chooser = new JalviewFileChooser("jvp",
+ "Jalview Project");
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager.getString("label.save_state"));
{
if (v_client != null)
{
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "vdj",// TODO: VAMSAS DOCUMENT EXTENSION is VDJ
+ // TODO: VAMSAS DOCUMENT EXTENSION is VDJ
+ JalviewFileChooser chooser = new JalviewFileChooser("vdj",
"Vamsas Document");
chooser.setFileView(new JalviewFileView());
void load()
{
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "fc",
+ JalviewFileChooser chooser = new JalviewFileChooser("fc",
"Sequence Feature Colours");
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager
void save()
{
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "fc",
+ JalviewFileChooser chooser = new JalviewFileChooser("fc",
"Sequence Feature Colours");
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager
try
{
JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"),
ImageMaker.EPS_EXTENSION, ImageMaker.EPS_EXTENSION);
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager
try
{
JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"),
ImageMaker.PNG_EXTENSION, ImageMaker.PNG_DESCRIPTION);
chooser.setFileView(new jalview.io.JalviewFileView());
package jalview.gui;
import jalview.api.structures.JalviewStructureDisplayI;
-import jalview.bin.Cache;
import jalview.datamodel.SequenceGroup;
import jalview.io.JalviewFileChooser;
import jalview.io.JalviewFileView;
upperCaseButtons = new ArrayList<JButton>();
lowerCaseButtons = new ArrayList<JButton>();
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "jc",
+ JalviewFileChooser chooser = new JalviewFileChooser("jc",
"Jalview User Colours");
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager
userColourSchemes.remove(schemeName.getText());
}
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "jc",
+ JalviewFileChooser chooser = new JalviewFileChooser("jc",
"Jalview User Colours");
chooser.setFileView(new JalviewFileView());
}
if (filename == null)
{
- JalviewFileChooser chooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "wsparams",
+ JalviewFileChooser chooser = new JalviewFileChooser("wsparams",
"Web Service Parameter File");
chooser.setFileView(new JalviewFileView());
chooser.setDialogTitle(MessageManager
package jalview.io;
import jalview.api.AlignExportSettingI;
-import jalview.bin.Cache;
import jalview.datamodel.AlignmentExportData;
import jalview.exceptions.NoFileSelectedException;
import jalview.gui.AlignmentPanel;
pSessionId);
}
- JalviewFileChooser jvFileChooser = new JalviewFileChooser(
- Cache.getProperty("LAST_DIRECTORY"), "html", "HTML files");
+ JalviewFileChooser jvFileChooser = new JalviewFileChooser("html",
+ "HTML files");
jvFileChooser.setFileView(new JalviewFileView());
jvFileChooser.setDialogTitle(MessageManager
//////////////////////////////////////////////////////////////////
package jalview.io;
+import jalview.bin.Cache;
import jalview.gui.JvOptionPane;
import jalview.util.MessageManager;
import jalview.util.Platform;
/**
* Constructor for a single choice of file extension and description
*
- * @param dir
* @param extension
* @param desc
*/
- public JalviewFileChooser(String dir, String extension, String desc)
+ public JalviewFileChooser(String extension, String desc)
{
- // TODO inline dir as Cache.getProperty("LAST_DIRECTORY") ? if applet
- // builds ok
- this(dir, new String[] { extension }, new String[] { desc }, desc,
- true);
+ this(Cache.getProperty("LAST_DIRECTORY"), new String[] { extension },
+ new String[] { desc }, desc, true);
}
JalviewFileChooser(String dir, String[] extensions, String[] descs,
*/
package jalview.util;
-import jalview.bin.Cache;
import jalview.bin.Jalview;
import jalview.gui.EPSOptions;
import jalview.gui.IProgressIndicator;
{
return null;
}
- return new JalviewFileChooser(Cache.getProperty("LAST_DIRECTORY"),
- PNG_EXTENSION, PNG_DESCRIPTION);
+ return new JalviewFileChooser(PNG_EXTENSION, PNG_DESCRIPTION);
}
static JalviewFileChooser getEPSChooser()
{
return null;
}
- return new JalviewFileChooser(Cache.getProperty("LAST_DIRECTORY"),
- EPS_EXTENSION, EPS_DESCRIPTION);
+ return new JalviewFileChooser(EPS_EXTENSION, EPS_DESCRIPTION);
}
private void setProgressMessage(String message)
{
return null;
}
- return new JalviewFileChooser(Cache.getProperty("LAST_DIRECTORY"),
- SVG_EXTENSION, SVG_DESCRIPTION);
+ return new JalviewFileChooser(SVG_EXTENSION, SVG_DESCRIPTION);
}
}