Browse Source

REPORT-9360【10.0一轮回归】模板名有特殊符号无法预览

master
vito 7 years ago
parent
commit
28e57935bc
  1. 4
      designer-base/src/com/fr/file/FILEChooserPane.java

4
designer-base/src/com/fr/file/FILEChooserPane.java

@ -674,7 +674,7 @@ public class FILEChooserPane extends BasicPane {
private void saveDialog() { private void saveDialog() {
String filename = fileNameTextField.getText(); String filename = fileNameTextField.getText();
if (!filename.endsWith(suffix) && !filename.contains(CoreConstants.DOT)) { if (!filename.endsWith(suffix)) {
ChooseFileFilter chooseFileFilter = (ChooseFileFilter) (postfixComboBox.getSelectedItem()); ChooseFileFilter chooseFileFilter = (ChooseFileFilter) (postfixComboBox.getSelectedItem());
if (chooseFileFilter != null && StringUtils.isNotEmpty(chooseFileFilter.getExtensionString())) { if (chooseFileFilter != null && StringUtils.isNotEmpty(chooseFileFilter.getExtensionString())) {
fileNameTextField.setText(filename + chooseFileFilter.getExtensionString()); fileNameTextField.setText(filename + chooseFileFilter.getExtensionString());
@ -1109,7 +1109,7 @@ public class FILEChooserPane extends BasicPane {
((DefaultListModel) subFileList.getModel()).removeAllElements(); ((DefaultListModel) subFileList.getModel()).removeAllElements();
for (int i = 0; i < res_array.length; i++) { for (int i = 0; i < res_array.length; i++) {
if (filter == null || filter.accept(res_array[i])) { if (filter == null || filter.accept(res_array[i])) {
((DefaultListModel) subFileList.getModel()).addElement( res_array[i]); ((DefaultListModel) subFileList.getModel()).addElement(res_array[i]);
} }
} }
String[] name_array = new String[res_array.length]; String[] name_array = new String[res_array.length];

Loading…
Cancel
Save