Java Code Examples for javax.swing.JFileChooser.SAVE_DIALOG

The following are Jave code examples for showing how to use SAVE_DIALOG of the javax.swing.JFileChooser class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: rapidminer   File: FileChooserUI.java   Source Code and License Vote up 5 votes
private Icon getApproveButtonIcon(JFileChooser fc) {
	if (fc.getDialogType() == JFileChooser.OPEN_DIALOG) {
		return FILECHOOSER_OPEN_ICON;
	}
	if (fc.getDialogType() == JFileChooser.SAVE_DIALOG) {
		return FILECHOOSER_SAVE_ICON;
	}
	if (fc.getDialogType() == JFileChooser.CUSTOM_DIALOG) {
		return FILECHOOSER_SELECT_ICON;
	}
	return FILECHOOSER_SELECT_ICON;
}
 
Example 2
Project: rapidminer   File: FileChooserUI.java   Source Code and License Vote up 5 votes
private void doDialogTypeChanged(PropertyChangeEvent e) {
	JFileChooser chooser = getFileChooser();
	this.approveButton.setText(getApproveButtonText(chooser));
	this.approveButton.setToolTipText(getApproveButtonToolTipText(chooser));
	this.approveButton.setIcon(getApproveButtonIcon(chooser));
	if (chooser.getDialogType() == JFileChooser.SAVE_DIALOG) {
		this.lookInLabel.setText(this.saveInLabelText);
	} else {
		this.lookInLabel.setText(this.lookInLabelText);
	}
}