|
|
|
@ -1,6 +1,8 @@
|
|
|
|
|
package com.fr.env.detect.ui; |
|
|
|
|
|
|
|
|
|
import com.fr.base.i18n.BidiUtils; |
|
|
|
|
import com.fr.base.svg.IconUtils; |
|
|
|
|
import com.fr.design.carton.FeedbackToolboxDialog; |
|
|
|
|
import com.fr.design.components.notification.NotificationDialog; |
|
|
|
|
import com.fr.design.components.notification.NotificationDialogProperties; |
|
|
|
|
import com.fr.design.components.notification.NotificationModel; |
|
|
|
@ -24,9 +26,6 @@ import com.fr.env.detect.bean.DetectorResult;
|
|
|
|
|
import com.fr.env.detect.bean.DetectorStatus; |
|
|
|
|
import com.fr.env.detect.bean.DetectorType; |
|
|
|
|
import com.fr.log.FineLoggerFactory; |
|
|
|
|
import com.fr.design.carton.FeedbackToolboxDialog; |
|
|
|
|
import com.fr.stable.ProductConstantsBase; |
|
|
|
|
import com.fr.stable.StableUtils; |
|
|
|
|
import org.jetbrains.annotations.NotNull; |
|
|
|
|
|
|
|
|
|
import javax.swing.BorderFactory; |
|
|
|
@ -38,14 +37,13 @@ import javax.swing.plaf.ButtonUI;
|
|
|
|
|
import java.awt.BorderLayout; |
|
|
|
|
import java.awt.Color; |
|
|
|
|
import java.awt.Component; |
|
|
|
|
import java.awt.Cursor; |
|
|
|
|
import java.awt.Dimension; |
|
|
|
|
import java.awt.Frame; |
|
|
|
|
import java.awt.Graphics2D; |
|
|
|
|
import java.awt.Image; |
|
|
|
|
import java.awt.Cursor; |
|
|
|
|
import java.awt.event.MouseAdapter; |
|
|
|
|
import java.awt.event.MouseEvent; |
|
|
|
|
import java.io.File; |
|
|
|
|
import java.net.URL; |
|
|
|
|
import java.util.List; |
|
|
|
|
import java.util.Map; |
|
|
|
@ -174,7 +172,7 @@ public class EnvDetectorDialog extends JDialog {
|
|
|
|
|
detectButton.setPreferredSize(new Dimension(68, 20)); |
|
|
|
|
detectButton.setBorderPainted(false); |
|
|
|
|
detectButton.setContentAreaFilled(false); |
|
|
|
|
headerPanel.add(detectButton, BorderLayout.WEST); |
|
|
|
|
headerPanel.add(detectButton, BorderLayout.LINE_START); |
|
|
|
|
|
|
|
|
|
UILabel openUtilBoxLabel = new UILabel(Toolkit.i18nText("Fine-Design_Basic_Carton_Feedback_ToolBox")); |
|
|
|
|
openUtilBoxLabel.setForeground(UIConstants.FLESH_BLUE); |
|
|
|
@ -195,8 +193,8 @@ public class EnvDetectorDialog extends JDialog {
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
headerPanel.add(openUtilBoxLabel, BorderLayout.EAST); |
|
|
|
|
return headerPanel; |
|
|
|
|
headerPanel.add(openUtilBoxLabel, BorderLayout.LINE_END); |
|
|
|
|
return BidiUtils.applyOrientationByLocale(headerPanel); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void startDetecting() { |
|
|
|
@ -342,7 +340,7 @@ public class EnvDetectorDialog extends JDialog {
|
|
|
|
|
|
|
|
|
|
updateTable(tablePanel); |
|
|
|
|
|
|
|
|
|
return tablePanel; |
|
|
|
|
return BidiUtils.applyOrientationByLocale(tablePanel); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void updateTable(TablePanel tablePanel) { |
|
|
|
@ -446,11 +444,11 @@ public class EnvDetectorDialog extends JDialog {
|
|
|
|
|
UICheckBox source = (UICheckBox) e.getSource(); |
|
|
|
|
EnvDetectorDialog.this.detectOpen = source.isSelected(); |
|
|
|
|
}); |
|
|
|
|
configPanel.add(checkBox, BorderLayout.WEST); |
|
|
|
|
configPanel.add(checkBox, BorderLayout.LINE_START); |
|
|
|
|
UILabel description = new UILabel(Toolkit.i18nText("Fine-Design_Basic_Detect_Switch")); |
|
|
|
|
configPanel.add(description, BorderLayout.EAST); |
|
|
|
|
configPanel.add(description, BorderLayout.LINE_END); |
|
|
|
|
} |
|
|
|
|
tailPanel.add(configPanel, BorderLayout.WEST); |
|
|
|
|
tailPanel.add(configPanel, BorderLayout.LINE_START); |
|
|
|
|
|
|
|
|
|
JPanel actionsPanel = FRGUIPaneFactory.createBorderLayout_S_Pane(); |
|
|
|
|
actionsPanel.setLayout(FRGUIPaneFactory.createM_BorderLayout()); |
|
|
|
@ -462,17 +460,17 @@ public class EnvDetectorDialog extends JDialog {
|
|
|
|
|
// 配置处理
|
|
|
|
|
EnvDetectorConfig.getInstance().setEnabled(this.detectOpen); |
|
|
|
|
}); |
|
|
|
|
actionsPanel.add(confirmButton, BorderLayout.WEST); |
|
|
|
|
actionsPanel.add(confirmButton, BorderLayout.LINE_START); |
|
|
|
|
|
|
|
|
|
UIButton cancelButton = new UIButton(Toolkit.i18nText("Fine-Design_Basic_Cancel")); |
|
|
|
|
cancelButton.addActionListener((e) -> { |
|
|
|
|
setVisible(false); |
|
|
|
|
dispose(); |
|
|
|
|
}); |
|
|
|
|
actionsPanel.add(cancelButton, BorderLayout.EAST); |
|
|
|
|
actionsPanel.add(cancelButton, BorderLayout.LINE_END); |
|
|
|
|
} |
|
|
|
|
tailPanel.add(actionsPanel, BorderLayout.EAST); |
|
|
|
|
return tailPanel; |
|
|
|
|
tailPanel.add(actionsPanel, BorderLayout.LINE_END); |
|
|
|
|
return BidiUtils.applyOrientationByLocale(tailPanel); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private void refreshHeader() { |
|
|
|
|