Browse Source

Merge pull request #320 in DESIGN/design from ~MATA.LI/designrel:release/10.0 to release/10.0

* commit '23733ff80c299e477330f34cf2b03674e80b5c19':
  REPORT-10385
  REPORT-10385
research/10.0
Mata.Li 6 years ago
parent
commit
c6b8269d03
  1. 10
      designer-realize/src/main/java/com/fr/start/module/DesignerWorkspaceProvider.java

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

@ -2,12 +2,14 @@ package com.fr.start.module;
import com.fr.design.DesignerEnvManager;
import com.fr.design.env.DesignerWorkspaceGenerator;
import com.fr.design.env.DesignerWorkspaceInfo;
import com.fr.design.mainframe.TemplatePane;
import com.fr.general.ComparatorUtils;
import com.fr.module.Activator;
import com.fr.workspace.WorkContext;
import com.fr.workspace.Workspace;
/**
* Created by juhaoyu on 2018/1/8.
* 设计器启动时的环境相关模块activator
@ -24,8 +26,10 @@ public class DesignerWorkspaceProvider extends Activator {
} else {
try {
String current = DesignerEnvManager.getEnvManager().getCurEnvName();
Workspace workspace = DesignerWorkspaceGenerator.generate(DesignerEnvManager.getEnvManager().getWorkspaceInfo(current));
if (workspace == null) {
DesignerWorkspaceInfo workspaceInfo = DesignerEnvManager.getEnvManager().getWorkspaceInfo(current);
Workspace workspace = DesignerWorkspaceGenerator.generate(workspaceInfo);
boolean checkValid = workspace == null ? false : workspaceInfo.checkValid();
if (!checkValid) {
TemplatePane.getInstance().dealEvnExceptionWhenStartDesigner();
} else {
WorkContext.switchTo(workspace);

Loading…
Cancel
Save