Browse Source

Merge branch 'release/10.0' of https://code.fineres.com/scm/~qinghui.liu/design into release/10.0

feature/big-screen
Qinghui.Liu 4 years ago
parent
commit
c966fc11fc
  1. 17
      designer-base/src/main/java/com/fr/design/DesignerEnvManager.java
  2. 46
      designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java
  3. 129
      designer-base/src/main/java/com/fr/design/parameter/ParameterArrayPane.java
  4. 16
      designer-base/src/main/java/com/fr/env/RemoteEnvPane.java
  5. 3
      designer-chart/src/main/java/com/fr/van/chart/box/data/table/BoxPlotTableResultDataSeriesPane.java
  6. 1
      designer-chart/src/main/java/com/fr/van/chart/box/data/table/UIComboBoxWithEditLabel.java
  7. 2
      designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java

17
designer-base/src/main/java/com/fr/design/DesignerEnvManager.java

@ -418,21 +418,10 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
this.isHttps = isHttps; this.isHttps = isHttps;
} }
public String getCertificatePath() {
return certificatePath;
}
public void setCertificatePath(String certificatePath) { public void setCertificatePath(String certificatePath) {
this.certificatePath = certificatePath; this.certificatePath = certificatePath;
} }
public String getCertificatePass() {
return certificatePass;
}
public void setCertificatePass(String certificatePass) { public void setCertificatePass(String certificatePass) {
this.certificatePass = certificatePass; this.certificatePass = certificatePass;
} }
@ -2015,11 +2004,13 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
private void writeHttpsParas(XMLPrintWriter writer) { private void writeHttpsParas(XMLPrintWriter writer) {
writer.startTAG(CAS_PARAS); writer.startTAG(CAS_PARAS);
// 这边的密钥path和password没有用处了 当前已经全部储存在对应的WorkspaceConnectionInfo中
// 把历史遗留保存的全部置为空 防止显示明文密钥 后面删除 todo
if (StringUtils.isNotBlank(certificatePath)) { if (StringUtils.isNotBlank(certificatePath)) {
writer.attr(CAS_CERTIFICATE_PATH, certificatePath); writer.attr(CAS_CERTIFICATE_PATH, StringUtils.EMPTY);
} }
if (StringUtils.isNotBlank(certificatePass)) { if (StringUtils.isNotBlank(certificatePass)) {
writer.attr(CAS_CERTIFICATE_PASSWORD, certificatePass); writer.attr(CAS_CERTIFICATE_PASSWORD, StringUtils.EMPTY);
} }
if (isHttps) { if (isHttps) {
writer.attr("enable", true); writer.attr("enable", true);

46
designer-base/src/main/java/com/fr/design/data/datapane/preview/PreviewTablePane.java

@ -15,20 +15,31 @@ import com.fr.design.data.DesignTableDataManager;
import com.fr.design.dialog.BasicDialog; import com.fr.design.dialog.BasicDialog;
import com.fr.design.dialog.BasicPane; import com.fr.design.dialog.BasicPane;
import com.fr.design.dialog.FineJOptionPane; import com.fr.design.dialog.FineJOptionPane;
import com.fr.design.file.HistoryTemplateListPane; import com.fr.design.file.HistoryTemplateListCache;
import com.fr.design.gui.frpane.UITabbedPane; import com.fr.design.gui.frpane.UITabbedPane;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.gui.iprogressbar.AutoProgressBar; import com.fr.design.gui.iprogressbar.AutoProgressBar;
import com.fr.design.gui.itable.SortableJTable; import com.fr.design.gui.itable.SortableJTable;
import com.fr.design.gui.itable.TableSorter; import com.fr.design.gui.itable.TableSorter;
import com.fr.design.gui.itextfield.UINumberField; import com.fr.design.gui.itextfield.UINumberField;
import com.fr.design.i18n.Toolkit;
import com.fr.design.layout.FRGUIPaneFactory; import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.mainframe.DesignerContext; import com.fr.design.mainframe.DesignerContext;
import com.fr.design.ui.util.UIUtil;
import com.fr.function.TIME; import com.fr.function.TIME;
import com.fr.general.FRFont; import com.fr.general.FRFont;
import com.fr.log.FineLoggerFactory; import com.fr.log.FineLoggerFactory;
import javax.swing.*; import javax.swing.BorderFactory;
import javax.swing.Icon;
import javax.swing.JComponent;
import javax.swing.JFrame;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTable;
import javax.swing.SwingWorker;
import javax.swing.UIManager;
import javax.swing.table.DefaultTableCellRenderer; import javax.swing.table.DefaultTableCellRenderer;
import javax.swing.table.TableColumn; import javax.swing.table.TableColumn;
import javax.swing.table.TableModel; import javax.swing.table.TableModel;
@ -81,7 +92,7 @@ public class PreviewTablePane extends BasicPane {
JPanel currentPreviewPanel = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); JPanel currentPreviewPanel = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane();
previewNumberPanel.add(currentPreviewPanel); previewNumberPanel.add(currentPreviewPanel);
currentPreviewPanel.add(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Current_Preview_Rows") + ":")); currentPreviewPanel.add(new UILabel(Toolkit.i18nText("Fine-Design_Basic_Current_Preview_Rows") + ":"));
currentRowsField = new UINumberField(); currentRowsField = new UINumberField();
currentPreviewPanel.add(currentRowsField); currentPreviewPanel.add(currentRowsField);
@ -91,7 +102,7 @@ public class PreviewTablePane extends BasicPane {
JPanel maxPanel = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); JPanel maxPanel = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane();
previewNumberPanel.add(maxPanel); previewNumberPanel.add(maxPanel);
maxPanel.add(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Datasource_Maximum_Number_of_Preview_Rows") + ":")); maxPanel.add(new UILabel(Toolkit.i18nText("Fine-Design_Basic_Datasource_Maximum_Number_of_Preview_Rows") + ":"));
maxPreviewNumberField = new UINumberField(); maxPreviewNumberField = new UINumberField();
maxPanel.add(maxPreviewNumberField); maxPanel.add(maxPreviewNumberField);
@ -158,7 +169,7 @@ public class PreviewTablePane extends BasicPane {
if (this.dialog == null) { if (this.dialog == null) {
this.dialog = this.showWindow(new JFrame()); this.dialog = this.showWindow(new JFrame());
} }
progressBar = new AutoProgressBar(this, com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Loading_Data"), "", 0, 100) { progressBar = new AutoProgressBar(this, Toolkit.i18nText("Fine-Design_Basic_Loading_Data"), "", 0, 100) {
public void doMonitorCanceled() { public void doMonitorCanceled() {
if (getWorker() != null) { if (getWorker() != null) {
getWorker().cancel(true); getWorker().cancel(true);
@ -174,7 +185,7 @@ public class PreviewTablePane extends BasicPane {
@Override @Override
protected String title4PopupWindow() { protected String title4PopupWindow() {
return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Preview"); return Toolkit.i18nText("Fine-Design_Basic_Preview");
} }
private void addLoadedListener(LoadedEventListener l) { private void addLoadedListener(LoadedEventListener l) {
@ -268,7 +279,7 @@ public class PreviewTablePane extends BasicPane {
*/ */
public static EmbeddedTableData previewTableData(TableData tableData, final int keyIndex, final int valueIndex) { public static EmbeddedTableData previewTableData(TableData tableData, final int keyIndex, final int valueIndex) {
PreviewTablePane previewTablePane = new PreviewTablePane(); PreviewTablePane previewTablePane = new PreviewTablePane();
previewTablePane.setBorder(BorderFactory.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Data"))); previewTablePane.setBorder(BorderFactory.createTitledBorder(Toolkit.i18nText("Fine-Design_Basic_Data")));
try { try {
previewTablePane.populate(tableData); previewTablePane.populate(tableData);
previewTablePane.resetPreviewTableColumnColor(); previewTablePane.resetPreviewTableColumnColor();
@ -298,13 +309,13 @@ public class PreviewTablePane extends BasicPane {
try { try {
int choiceColumn = Integer.parseInt(columnErrMessage.trim()); int choiceColumn = Integer.parseInt(columnErrMessage.trim());
int tatalColumn = Integer.parseInt(tatolColumnErrMessage.trim()); int tatalColumn = Integer.parseInt(tatolColumnErrMessage.trim());
columnErrMessage = com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Tabledata_Preview_Warn_Text", choiceColumn + 1, tatalColumn); columnErrMessage = Toolkit.i18nText("Fine-Design_Basic_Tabledata_Preview_Warn_Text", choiceColumn + 1, tatalColumn);
} catch (Exception e) { } catch (Exception e) {
FineLoggerFactory.getLogger().error(e.getMessage(), e); FineLoggerFactory.getLogger().error(e.getMessage(), e);
return; return;
} }
FineLoggerFactory.getLogger().error(exp.getMessage(), exp); FineLoggerFactory.getLogger().error(exp.getMessage(), exp);
FineJOptionPane.showMessageDialog(DesignerContext.getDesignerFrame(), columnErrMessage, com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Error"), JOptionPane.ERROR_MESSAGE); FineJOptionPane.showMessageDialog(DesignerContext.getDesignerFrame(), columnErrMessage, Toolkit.i18nText("Fine-Design_Basic_Error"), JOptionPane.ERROR_MESSAGE);
} }
private void populate(TableData tableData) throws Exception { private void populate(TableData tableData) throws Exception {
@ -317,7 +328,7 @@ public class PreviewTablePane extends BasicPane {
} }
private void previewTableDataSQL() throws Exception { private void previewTableDataSQL() throws Exception {
connectionBar = new AutoProgressBar(this, com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Utils_Now_Create_Connection"), "", 0, 100) { connectionBar = new AutoProgressBar(this, Toolkit.i18nText("Fine-Design_Basic_Utils_Now_Create_Connection"), "", 0, 100) {
public void doMonitorCanceled() { public void doMonitorCanceled() {
getWorker().cancel(true); getWorker().cancel(true);
getDialog().setVisible(false); getDialog().setVisible(false);
@ -365,13 +376,14 @@ public class PreviewTablePane extends BasicPane {
if (tableData instanceof DBTableData) { if (tableData instanceof DBTableData) {
boolean status = DataOperator.getInstance().testConnection(((DBTableData) tableData).getDatabase()); boolean status = DataOperator.getInstance().testConnection(((DBTableData) tableData).getDatabase());
if (!status) { if (!status) {
throw new Exception(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Database_Connection_Failed")); throw new Exception(Toolkit.i18nText("Fine-Design_Basic_Database_Connection_Failed"));
} }
} }
} finally { } finally {
connectionBar.close(); // 将close操作放到EDT线程中
UIUtil.invokeLaterIfNeeded(() -> connectionBar.close());
} }
TableDataSource dataSource = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate().getTarget(); TableDataSource dataSource = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate().getTarget();
previewTableData = DesignTableDataManager.previewTableDataNeedInputParameters(dataSource, tableData, (int) maxPreviewNumberField.getValue(), true, progressBar); previewTableData = DesignTableDataManager.previewTableDataNeedInputParameters(dataSource, tableData, (int) maxPreviewNumberField.getValue(), true, progressBar);
// parameterInputDialog // parameterInputDialog
// update之后的parameters,转成一个parameterMap,用于预览TableData // update之后的parameters,转成一个parameterMap,用于预览TableData
@ -396,7 +408,7 @@ public class PreviewTablePane extends BasicPane {
if (!(e instanceof CancellationException)) { if (!(e instanceof CancellationException)) {
FineLoggerFactory.getLogger().error(e.getMessage(), e); FineLoggerFactory.getLogger().error(e.getMessage(), e);
FineJOptionPane.showMessageDialog(DesignerContext.getDesignerFrame(), e.getMessage(), FineJOptionPane.showMessageDialog(DesignerContext.getDesignerFrame(), e.getMessage(),
com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Error"), JOptionPane.ERROR_MESSAGE, UIManager.getIcon("OptionPane.errorIcon")); Toolkit.i18nText("Fine-Design_Basic_Error"), JOptionPane.ERROR_MESSAGE, UIManager.getIcon("OptionPane.errorIcon"));
} }
dialog.setVisible(false); dialog.setVisible(false);
} finally { } finally {
@ -425,7 +437,7 @@ public class PreviewTablePane extends BasicPane {
public static void previewStoreData(final ProcedureDataModel storeProcedureDataModel, final int keyIndex, final int valueIndex) { public static void previewStoreData(final ProcedureDataModel storeProcedureDataModel, final int keyIndex, final int valueIndex) {
final PreviewTablePane previewTablePane = new PreviewTablePane(); final PreviewTablePane previewTablePane = new PreviewTablePane();
previewTablePane.storeProcedureDataModel = storeProcedureDataModel; previewTablePane.storeProcedureDataModel = storeProcedureDataModel;
previewTablePane.setBorder(BorderFactory.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Data"))); previewTablePane.setBorder(BorderFactory.createTitledBorder(Toolkit.i18nText("Fine-Design_Basic_Data")));
try { try {
previewTablePane.populateStoreDataSQL(); previewTablePane.populateStoreDataSQL();
@ -456,7 +468,7 @@ public class PreviewTablePane extends BasicPane {
for (int i = 0; i < tableSize; i++) { for (int i = 0; i < tableSize; i++) {
PreviewTablePane previewTablePane = new PreviewTablePane(); PreviewTablePane previewTablePane = new PreviewTablePane();
previewTablePane.storeProcedureDataModel = storeProcedureDataModels[i]; previewTablePane.storeProcedureDataModel = storeProcedureDataModels[i];
previewTablePane.setBorder(BorderFactory.createTitledBorder(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Data"))); previewTablePane.setBorder(BorderFactory.createTitledBorder(Toolkit.i18nText("Fine-Design_Basic_Data")));
try { try {
previewTablePane.populateStoreDataSQL(); previewTablePane.populateStoreDataSQL();
} catch (Exception e) { } catch (Exception e) {
@ -469,7 +481,7 @@ public class PreviewTablePane extends BasicPane {
@Override @Override
protected String title4PopupWindow() { protected String title4PopupWindow() {
return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Preview"); return Toolkit.i18nText("Fine-Design_Basic_Preview");
} }
}; };

129
designer-base/src/main/java/com/fr/design/parameter/ParameterArrayPane.java

@ -7,7 +7,7 @@ import com.fr.design.gui.controlpane.JListControlPane;
import com.fr.design.gui.controlpane.NameableCreator; import com.fr.design.gui.controlpane.NameableCreator;
import com.fr.design.gui.controlpane.NameableSelfCreator; import com.fr.design.gui.controlpane.NameableSelfCreator;
import com.fr.design.gui.controlpane.UnrepeatedNameHelper; import com.fr.design.gui.controlpane.UnrepeatedNameHelper;
import com.fr.design.gui.ilist.ModNameActionListener; import com.fr.design.i18n.Toolkit;
import com.fr.general.ComparatorUtils; import com.fr.general.ComparatorUtils;
import com.fr.stable.Nameable; import com.fr.stable.Nameable;
import com.fr.stable.StringUtils; import com.fr.stable.StringUtils;
@ -18,79 +18,74 @@ import java.util.Arrays;
import java.util.List; import java.util.List;
public class ParameterArrayPane extends JListControlPane { public class ParameterArrayPane extends JListControlPane {
/** /**
* Constructor. * Constructor.
*/ */
public ParameterArrayPane() { public ParameterArrayPane() {
super(); super();
this.addModNameActionListener(new ModNameActionListener() { this.addModNameActionListener((index, oldName, newName) -> populateSelectedValue());
public void nameModed(int index, String oldName, String newName) { this.addEditingListener(new PropertyChangeAdapter() {
populateSelectedValue(); public void propertyChange() {
} Parameter[] parameters = ParameterConfig.getInstance().getGlobalParameters();
String[] allListNames = nameableList.getAllNames();
allListNames[editingIndex] = StringUtils.EMPTY;
String tempName = getEditingName();
if (StringUtils.isEmpty(tempName)) {
nameableList.stopEditing();
FineJOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(ParameterArrayPane.this), com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Empty_Parameter_Name"));
setIllegalIndex(editingIndex);
return;
}
if (!ComparatorUtils.equals(tempName, selectedName)
&& isNameRepeated(new List[]{Arrays.asList(parameters), Arrays.asList(allListNames)}, tempName)) {
nameableList.stopEditing();
FineJOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(ParameterArrayPane.this),
Toolkit.i18nText("Fine-Design_Basic_Duplicate_Parameter_Name"));
setIllegalIndex(editingIndex);
}
}
});
}
});
this.addEditingListener(new PropertyChangeAdapter() {
public void propertyChange() {
Parameter[] parameters = ParameterConfig.getInstance().getGlobalParameters();
String[] allListNames = nameableList.getAllNames();
allListNames[nameableList.getSelectedIndex()] = StringUtils.EMPTY;
String tempName = getEditingName();
if (StringUtils.isEmpty(tempName)) {
nameableList.stopEditing();
FineJOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(ParameterArrayPane.this), com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Empty_Parameter_Name"));
setIllegalIndex(editingIndex);
return;
}
if (!ComparatorUtils.equals(tempName, selectedName)
&& isNameRepeated(new List[]{Arrays.asList(parameters), Arrays.asList(allListNames)}, tempName)) {
nameableList.stopEditing();
FineJOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(ParameterArrayPane.this),
com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Duplicate_Parameter_Name"));
setIllegalIndex(editingIndex);
}
}
});
}
@Override
protected String title4PopupWindow() {
return Toolkit.i18nText("Fine-Design_Basic_Engine_Schedule_Template_Parameter");
}
@Override /**
protected String title4PopupWindow() { * 创建模板参数设置组件
return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Engine_Schedule_Template_Parameter"); *
} * @return 模板参数设置组件
*/
/** public NameableCreator[] createNameableCreators() {
* 创建模板参数设置组件 return new NameableCreator[]{
* new NameableSelfCreator(Toolkit.i18nText("Fine-Design_Basic_Engine_Parameter_Name"), Parameter.class, ParameterPane.class) {
* @return 模板参数设置组件 public Parameter createNameable(UnrepeatedNameHelper helper) {
*/ // 返回参数设置面板.
public NameableCreator[] createNameableCreators() { return new Parameter(helper.createUnrepeatedName("p"));
return new NameableCreator[]{ }
new NameableSelfCreator(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Engine_Parameter_Name"), Parameter.class, ParameterPane.class) {
public Parameter createNameable(UnrepeatedNameHelper helper) {
// 返回参数设置面板.
return new Parameter(helper.createUnrepeatedName("p"));
}
@Override @Override
public String createTooltip() { public String createTooltip() {
return null; return null;
} }
} }
}; };
} }
/** /**
* 更新参数 * 更新参数
* *
* @return 更新后的参数 * @return 更新后的参数
*/ */
public Parameter[] updateParameters() { public Parameter[] updateParameters() {
// Nameable[]居然不能强转成Parameter[],一定要这么写... // Nameable[]居然不能强转成Parameter[],一定要这么写...
Nameable[] res = this.update(); Nameable[] res = this.update();
Parameter[] res_array = new Parameter[res.length]; Parameter[] res_array = new Parameter[res.length];
java.util.Arrays.asList(res).toArray(res_array); Arrays.asList(res).toArray(res_array);
return res_array; return res_array;
} }
} }

16
designer-base/src/main/java/com/fr/env/RemoteEnvPane.java vendored

@ -143,6 +143,12 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
* https 证书路径输入框 * https 证书路径输入框
*/ */
private JPanel httpsCertFileInputPanel; private JPanel httpsCertFileInputPanel;
/**
* 当前远程工作目录是否为新创建的
*/
private boolean newCreated;
/** /**
* 主机名web应用Servlet端口监听器 * 主机名web应用Servlet端口监听器
*/ */
@ -327,7 +333,7 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
this.certPathInput.setText(certPath); this.certPathInput.setText(certPath);
this.certSecretKeyInput.setText(certSecretKey); this.certSecretKeyInput.setText(certSecretKey);
this.rememberPwdCheckbox.setSelected(rememberPwd); this.rememberPwdCheckbox.setSelected(rememberPwd);
this.newCreated = ob.isNewCreated();
} else { } else {
this.remoteWorkspaceURL = RemoteWorkspaceURL.createDefaultURL(); this.remoteWorkspaceURL = RemoteWorkspaceURL.createDefaultURL();
this.usernameInput.setText(StringUtils.EMPTY); this.usernameInput.setText(StringUtils.EMPTY);
@ -335,6 +341,7 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
this.certPathInput.setText(StringUtils.EMPTY); this.certPathInput.setText(StringUtils.EMPTY);
this.certSecretKeyInput.setText(StringUtils.EMPTY); this.certSecretKeyInput.setText(StringUtils.EMPTY);
this.rememberPwdCheckbox.setSelected(true); this.rememberPwdCheckbox.setSelected(true);
this.newCreated = true;
} }
fillRemoteEnvURLField(); fillRemoteEnvURLField();
@ -366,7 +373,9 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
new String(this.certSecretKeyInput.getPassword()), new String(this.certSecretKeyInput.getPassword()),
rememberPwd); rememberPwd);
return RemoteDesignerWorkspaceInfo.create(connection); RemoteDesignerWorkspaceInfo info = RemoteDesignerWorkspaceInfo.create(connection);
info.setNewCreated(newCreated);
return info;
} }
@Override @Override
@ -567,9 +576,6 @@ public class RemoteEnvPane extends BasicBeanPane<RemoteDesignerWorkspaceInfo> {
@Override @Override
protected TestConnectionResult doInBackground() throws Exception { protected TestConnectionResult doInBackground() throws Exception {
DesignerEnvManager.getEnvManager().setCertificatePath(connection.getCertPath());
DesignerEnvManager.getEnvManager().setCertificatePass(connection.getCertSecretKey());
try { try {
return TestConnectionResult.parse(WorkContext.getConnector().testConnection(connection), connection); return TestConnectionResult.parse(WorkContext.getConnector().testConnection(connection), connection);
} catch (WorkspaceAuthException ignored) { } catch (WorkspaceAuthException ignored) {

3
designer-chart/src/main/java/com/fr/van/chart/box/data/table/BoxPlotTableResultDataSeriesPane.java

@ -15,10 +15,10 @@ import com.fr.stable.StringUtils;
import javax.swing.BorderFactory; import javax.swing.BorderFactory;
import javax.swing.JPanel; import javax.swing.JPanel;
import java.util.List;
import java.awt.BorderLayout; import java.awt.BorderLayout;
import java.awt.Component; import java.awt.Component;
import java.awt.Dimension; import java.awt.Dimension;
import java.util.List;
public class BoxPlotTableResultDataSeriesPane extends AbstractTableDataContentPane { public class BoxPlotTableResultDataSeriesPane extends AbstractTableDataContentPane {
@ -66,6 +66,7 @@ public class BoxPlotTableResultDataSeriesPane extends AbstractTableDataContentPa
private JPanel createUIComboBoxPane(UIComboBox comboBox, String title) { private JPanel createUIComboBoxPane(UIComboBox comboBox, String title) {
UILabel label = new UILabel(title); UILabel label = new UILabel(title);
label.setPreferredSize(new Dimension(80, 20)); label.setPreferredSize(new Dimension(80, 20));
comboBox.setPreferredSize(new Dimension(100, 20));
JPanel panel = new JPanel(); JPanel panel = new JPanel();

1
designer-chart/src/main/java/com/fr/van/chart/box/data/table/UIComboBoxWithEditLabel.java

@ -31,6 +31,7 @@ public abstract class UIComboBoxWithEditLabel extends JPanel implements UIObserv
editLabel.setPreferredSize(new Dimension(80, 20)); editLabel.setPreferredSize(new Dimension(80, 20));
comboBox = new UIComboBox(); comboBox = new UIComboBox();
comboBox.setPreferredSize(new Dimension(100, 20));
this.setLayout(new BorderLayout(4, 0)); this.setLayout(new BorderLayout(4, 0));
this.add(editLabel, BorderLayout.WEST); this.add(editLabel, BorderLayout.WEST);

2
designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java

@ -384,7 +384,7 @@ public class EditingMouseListener extends MouseInputAdapter {
if (component.getCoverPane().getComponentCount() > 1) { if (component.getCoverPane().getComponentCount() > 1) {
JComponent button1 = (JComponent) component.getCoverPane().getComponent(1); JComponent button1 = (JComponent) component.getCoverPane().getComponent(1);
int minX1 = button1.getX() + getParentPositionX(component, 0) - designer.getHorizontalScaleValue(); int minX1 = button1.getX() + getParentPositionX(component, 0) - designer.getHorizontalScaleValue();
int minY1 = button1.getY() + getParentPositionY(component, 0) - designer.getVerticalScaleValue(); int minY1 = button1.getY() + getParentPositionY(component, 0) - designer.getVerticalScaleValue() + component.getY();
if (e.getX() + GAP - component.getInsets().left > minX1 && e.getX() - GAP - component.getInsets().left < minX1 + button1.getWidth()) { if (e.getX() + GAP - component.getInsets().left > minX1 && e.getX() - GAP - component.getInsets().left < minX1 + button1.getWidth()) {
if (e.getY() + GAP - component.getInsets().top > minY1 && e.getY() - GAP - component.getInsets().top < minY1 + button1.getHeight()) { if (e.getY() + GAP - component.getInsets().top > minY1 && e.getY() - GAP - component.getInsets().top < minY1 + button1.getHeight()) {
designer.setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR)); designer.setCursor(Cursor.getPredefinedCursor(Cursor.HAND_CURSOR));

Loading…
Cancel
Save