Browse Source

Merge pull request #334 in DESIGN/design from ~JU/design:release/10.0 to release/10.0

* commit '6920ab1240d8a54c337b581424e0812567de409c':
  无JIRA任务 打包
  无JIRA任务 代码质量
  无JIRA任务 本来就是默认路径时起不来
  无JIRA任务 本来就是默认路径时起不来
final/10.0
ju 6 years ago
parent
commit
2092bbcdd5
  1. 19
      designer-base/src/main/java/com/fr/design/DesignerEnvManager.java
  2. 1
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/style/ChartAxisLineStylePane.java
  3. 2
      designer-realize/src/main/java/com/fr/start/module/DesignerWorkspaceProvider.java

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

@ -482,20 +482,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
public void setLastEastRegionContainerWidth(int eastRegionContainerWidth) {
this.eastRegionContainerWidth = eastRegionContainerWidth;
}
/**
* 判断当前环境是否为默认
*
* @return 是默认则返回true
*/
public boolean isCurrentEnvDefault() {
DesignerWorkspaceInfo current = this.getWorkspaceInfo(curEnvName);
String defaultEnvPath = getDefaultenvPath(StableUtils.getInstallHome());
return ComparatorUtils.equals(defaultEnvPath, current.getPath());
}
/**
* 返回默认环境
*/
@ -547,9 +534,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
* 设置当前环境为默认
*/
public void setCurrentEnv2Default() {
if (isCurrentEnvDefault()) {
return;
}
try {
final String envName = getDefaultEnvName();
WorkContext.switchTo(DesignerWorkspaceGenerator.generate(getDefaultConfig()), new WorkContextCallback() {

1
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/style/ChartAxisLineStylePane.java

@ -35,7 +35,6 @@ public class ChartAxisLineStylePane extends BasicPane{
String[] nameArray = {com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_External"),com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Inner"),com.fr.design.i18n.Toolkit.i18nText("ChartF-Cross"),com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_None")};
Integer[] valueArray = {Constants.TICK_MARK_OUTSIDE, Constants.TICK_MARK_INSIDE, Constants.TICK_MARK_CROSS, Constants.TICK_MARK_NONE};
Icon[] iconArray = {BaseUtils.readIcon("/com/fr/design/images/chart/ChartAxisLineStyle/external.png"),
BaseUtils.readIcon("/com/fr/design/images/chart/ChartAxisLineStyle/inside.png"),

2
designer-realize/src/main/java/com/fr/start/module/DesignerWorkspaceProvider.java

@ -28,7 +28,7 @@ public class DesignerWorkspaceProvider extends Activator {
String current = DesignerEnvManager.getEnvManager().getCurEnvName();
DesignerWorkspaceInfo workspaceInfo = DesignerEnvManager.getEnvManager().getWorkspaceInfo(current);
Workspace workspace = DesignerWorkspaceGenerator.generate(workspaceInfo);
boolean checkValid = workspace == null ? false : workspaceInfo.checkValid();
boolean checkValid = workspace != null && workspaceInfo.checkValid();
if (!checkValid) {
TemplatePane.getInstance().dealEvnExceptionWhenStartDesigner();
} else {

Loading…
Cancel
Save