Browse Source

Merge remote-tracking branch 'origin/release/10.0' into release/10.0

feature/big-screen
alex.sung 5 years ago
parent
commit
b4d42c10fb
  1. 63
      designer-base/src/main/java/com/fr/design/actions/file/PreferencePane.java
  2. 12
      designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java
  3. 3
      designer-base/src/main/java/com/fr/design/file/MutilTempalteTabPane.java
  4. 1
      designer-base/src/main/java/com/fr/design/update/ui/dialog/RestoreResultDialog.java
  5. 4
      designer-base/src/main/java/com/fr/design/update/ui/dialog/UpdateMainDialog.java
  6. 2
      designer-realize/src/main/java/com/fr/design/write/submit/SmartInsertDBManipulationPane.java

63
designer-base/src/main/java/com/fr/design/actions/file/PreferencePane.java

@ -1,7 +1,6 @@
package com.fr.design.actions.file; package com.fr.design.actions.file;
import com.fr.config.Configuration; import com.fr.config.Configuration;
import com.fr.config.ServerPreferenceConfig;
import com.fr.design.DesignerEnvManager; import com.fr.design.DesignerEnvManager;
import com.fr.design.RestartHelper; import com.fr.design.RestartHelper;
import com.fr.design.constants.UIConstants; import com.fr.design.constants.UIConstants;
@ -197,20 +196,20 @@ public class PreferencePane extends BasicPane {
oracleSpace = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Show_All_Oracle_Tables")); oracleSpace = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Show_All_Oracle_Tables"));
oraclePane.add(oracleSpace); oraclePane.add(oracleSpace);
JPanel debuggerPane = FRGUIPaneFactory.createTitledBorderPane(Toolkit.i18nText("Fine-Design_Basic_Develop_Tools")); // JPanel debuggerPane = FRGUIPaneFactory.createTitledBorderPane(Toolkit.i18nText("Fine-Design_Basic_Develop_Tools"));
openDebugComboBox = new UICheckBox(Toolkit.i18nText("Fine-Design_Basic_Open_Debug_Window")); // openDebugComboBox = new UICheckBox(Toolkit.i18nText("Fine-Design_Basic_Open_Debug_Window"));
debuggerPane.add(openDebugComboBox, BorderLayout.CENTER); // debuggerPane.add(openDebugComboBox, BorderLayout.CENTER);
advancePane.add(debuggerPane); // advancePane.add(debuggerPane);
//
JPanel upmSelectorPane = FRGUIPaneFactory.createTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Update_Plugin_Manager")); // JPanel upmSelectorPane = FRGUIPaneFactory.createTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Update_Plugin_Manager"));
useOptimizedUPMCheckbox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Use_New_Update_Plugin_Manager")); // useOptimizedUPMCheckbox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Use_New_Update_Plugin_Manager"));
upmSelectorPane.add(useOptimizedUPMCheckbox); // upmSelectorPane.add(useOptimizedUPMCheckbox);
advancePane.add(upmSelectorPane); // advancePane.add(upmSelectorPane);
//
JPanel dbmSelectorPane = FRGUIPaneFactory.createTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Database_Manager")); // JPanel dbmSelectorPane = FRGUIPaneFactory.createTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Database_Manager"));
useUniverseDBMCheckbox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Use_Universe_Database_Manager")); // useUniverseDBMCheckbox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Use_Universe_Database_Manager"));
dbmSelectorPane.add(useUniverseDBMCheckbox); // dbmSelectorPane.add(useUniverseDBMCheckbox);
advancePane.add(dbmSelectorPane); // advancePane.add(dbmSelectorPane);
JPanel improvePane = FRGUIPaneFactory.createVerticalTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Product_Improve")); JPanel improvePane = FRGUIPaneFactory.createVerticalTitledBorderPane(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Product_Improve"));
joinProductImproveCheckBox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Join_Product_Improve")); joinProductImproveCheckBox = new UICheckBox(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Join_Product_Improve"));
@ -674,10 +673,10 @@ public class PreferencePane extends BasicPane {
this.portEditor.setValue(new Integer(designerEnvManager.getEmbedServerPort())); this.portEditor.setValue(new Integer(designerEnvManager.getEmbedServerPort()));
openDebugComboBox.setSelected(designerEnvManager.isOpenDebug()); // openDebugComboBox.setSelected(designerEnvManager.isOpenDebug());
useOptimizedUPMCheckbox.setSelected(ServerPreferenceConfig.getInstance().isUseOptimizedUPM()); // useOptimizedUPMCheckbox.setSelected(ServerPreferenceConfig.getInstance().isUseOptimizedUPM());
//
useUniverseDBMCheckbox.setSelected(ServerPreferenceConfig.getInstance().isUseUniverseDBM()); // useUniverseDBMCheckbox.setSelected(ServerPreferenceConfig.getInstance().isUseUniverseDBM());
this.oracleSpace.setSelected(designerEnvManager.isOracleSystemSpace()); this.oracleSpace.setSelected(designerEnvManager.isOracleSystemSpace());
this.cachingTemplateSpinner.setValue(designerEnvManager.getCachingTemplateLimit()); this.cachingTemplateSpinner.setValue(designerEnvManager.getCachingTemplateLimit());
@ -742,7 +741,7 @@ public class PreferencePane extends BasicPane {
designerEnvManager.setJettyServerPort(portEditor.getValue().intValue()); designerEnvManager.setJettyServerPort(portEditor.getValue().intValue());
designerEnvManager.setOpenDebug(openDebugComboBox.isSelected()); // designerEnvManager.setOpenDebug(openDebugComboBox.isSelected());
designerEnvManager.setOracleSystemSpace(this.oracleSpace.isSelected()); designerEnvManager.setOracleSystemSpace(this.oracleSpace.isSelected());
designerEnvManager.setCachingTemplateLimit((int) this.cachingTemplateSpinner.getValue()); designerEnvManager.setCachingTemplateLimit((int) this.cachingTemplateSpinner.getValue());
@ -773,18 +772,18 @@ public class PreferencePane extends BasicPane {
} }
}); });
Configurations.update(new Worker() { // Configurations.update(new Worker() {
@Override // @Override
public void run() { // public void run() {
ServerPreferenceConfig.getInstance().setUseOptimizedUPM(useOptimizedUPMCheckbox.isSelected()); // ServerPreferenceConfig.getInstance().setUseOptimizedUPM(useOptimizedUPMCheckbox.isSelected());
ServerPreferenceConfig.getInstance().setUseUniverseDBM(useUniverseDBMCheckbox.isSelected()); // ServerPreferenceConfig.getInstance().setUseUniverseDBM(useUniverseDBMCheckbox.isSelected());
} // }
//
@Override // @Override
public Class<? extends Configuration>[] targets() { // public Class<? extends Configuration>[] targets() {
return new Class[] {ServerPreferenceConfig.class}; // return new Class[] {ServerPreferenceConfig.class};
} // }
}); // });
} }

12
designer-base/src/main/java/com/fr/design/file/HistoryTemplateListCache.java

@ -269,11 +269,6 @@ public class HistoryTemplateListCache implements CallbackEvent {
if (size == index + 1 && index > 0) { if (size == index + 1 && index > 0) {
//如果删除的是后一个Tab,则定位到前一个 //如果删除的是后一个Tab,则定位到前一个
MutilTempalteTabPane.getInstance().setSelectedIndex(index - 1); MutilTempalteTabPane.getInstance().setSelectedIndex(index - 1);
JTemplate selectedFile = MutilTempalteTabPane.getInstance().getSelectedFile();
if (!isCurrentEditingFile(selectedFile.getPath())) {
//如果此时面板上的实时刷新的selectedIndex得到的和历史的不一样
DesignerContext.getDesignerFrame().activateJTemplate(selectedFile);
}
} }
} }
} }
@ -282,6 +277,13 @@ public class HistoryTemplateListCache implements CallbackEvent {
if (openFileCount == 0) { if (openFileCount == 0) {
DesignerContext.getDesignerFrame().addAndActivateJTemplate(); DesignerContext.getDesignerFrame().addAndActivateJTemplate();
} }
JTemplate selectedFile = MutilTempalteTabPane.getInstance().getSelectedFile();
if (!isCurrentEditingFile(selectedFile.getPath())) {
//如果此时面板上的实时刷新的selectedIndex得到的和历史的不一样
DesignerContext.getDesignerFrame().activateJTemplate(selectedFile);
}
MutilTempalteTabPane.getInstance().repaint(); MutilTempalteTabPane.getInstance().repaint();
} }

3
designer-base/src/main/java/com/fr/design/file/MutilTempalteTabPane.java

@ -156,6 +156,9 @@ public class MutilTempalteTabPane extends JComponent {
} }
public JTemplate getSelectedFile() { public JTemplate getSelectedFile() {
if (openedTemplate.size() == selectedIndex) {
selectedIndex = Math.max(--selectedIndex, 0);
}
return openedTemplate.get(selectedIndex); return openedTemplate.get(selectedIndex);
} }

1
designer-base/src/main/java/com/fr/design/update/ui/dialog/RestoreResultDialog.java

@ -12,6 +12,7 @@ import com.fr.stable.StableUtils;
import com.fr.stable.StringUtils; import com.fr.stable.StringUtils;
import com.fr.stable.project.ProjectConstants; import com.fr.stable.project.ProjectConstants;
import javax.swing.AbstractAction; import javax.swing.AbstractAction;
import javax.swing.BorderFactory; import javax.swing.BorderFactory;
import javax.swing.JDialog; import javax.swing.JDialog;

4
designer-base/src/main/java/com/fr/design/update/ui/dialog/UpdateMainDialog.java

@ -362,10 +362,10 @@ public class UpdateMainDialog extends UIDialog {
add(jarVersionInfoPane, BorderLayout.NORTH); add(jarVersionInfoPane, BorderLayout.NORTH);
//海外版本不显示更新信息 //海外版本不显示更新信息
if (GeneralContext.getLocale().equals(Locale.CHINA) || GeneralContext.getLocale().equals(Locale.TAIWAN)){ if (GeneralContext.getLocale().equals(Locale.CHINA) || GeneralContext.getLocale().equals(Locale.TAIWAN)) {
add(jarUpdateInfoPane, BorderLayout.CENTER); add(jarUpdateInfoPane, BorderLayout.CENTER);
add(updateActionPane, BorderLayout.SOUTH); add(updateActionPane, BorderLayout.SOUTH);
}else { } else {
add(updateActionPane, BorderLayout.CENTER); add(updateActionPane, BorderLayout.CENTER);
} }

2
designer-realize/src/main/java/com/fr/design/write/submit/SmartInsertDBManipulationPane.java

@ -427,7 +427,7 @@ public class SmartInsertDBManipulationPane extends DBManipulationPane {
dealSelectColRow(add, cellselection); dealSelectColRow(add, cellselection);
} else { } else {
ColumnRow columnRow = ColumnRow.valueOf(cellselection.getColumn(), cellselection.getRow()); ColumnRow columnRow = ColumnRow.valueOf(cellselection.getColumn(), cellselection.getRow());
String allColumnRow = columnRow.toString(); String allColumnRow = newValue.toString();
if (!allColumnRow.contains(columnRow.toString())) { if (!allColumnRow.contains(columnRow.toString())) {
add.addColumnRow(columnRow); add.addColumnRow(columnRow);
} }

Loading…
Cancel
Save