|
|
|
@ -141,8 +141,8 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
private int eastRegionToolPaneY = 300; |
|
|
|
|
private int eastRegionContainerWidth = 260; |
|
|
|
|
|
|
|
|
|
private int westRegionToolPaneY = 300; |
|
|
|
|
private int westRegionContainerWidth = 240; |
|
|
|
|
private double westRegionToolPaneYRate = 0.5; |
|
|
|
|
private String encryptionKey; |
|
|
|
|
private String jdkHome; |
|
|
|
|
|
|
|
|
@ -240,7 +240,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
String installHome = StableUtils.getInstallHome(); |
|
|
|
|
//这里不判断路径是.的情况,放在checkValid方法里面,重新选
|
|
|
|
|
if (installHome != null) { |
|
|
|
|
String name = com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Engine_DEFAULT"); |
|
|
|
|
String name = Toolkit.i18nText("Fine-Design_Basic_Engine_DEFAULT"); |
|
|
|
|
String envPath = designerEnvManager.getDefaultenvPath(installHome); |
|
|
|
|
designerEnvManager.putEnv(name, LocalDesignerWorkspaceInfo.create(name, envPath)); |
|
|
|
|
designerEnvManager.setCurEnvName(name); |
|
|
|
@ -304,8 +304,8 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
String today = calender.get(Calendar.YEAR) + "-" + (calender.get(Calendar.MONTH) + 1) + "-" + calender.get(Calendar.DAY_OF_MONTH); |
|
|
|
|
|
|
|
|
|
String fileName = StableUtils.pathJoin(logLocation, "fr_" + today + "_%g.log"); |
|
|
|
|
if (!new java.io.File(fileName).exists()) { |
|
|
|
|
StableUtils.makesureFileExist(new java.io.File(fileName)); |
|
|
|
|
if (!new File(fileName).exists()) { |
|
|
|
|
StableUtils.makesureFileExist(new File(fileName)); |
|
|
|
|
} |
|
|
|
|
Handler handler = new FileHandler(fileName, true); |
|
|
|
|
|
|
|
|
@ -440,12 +440,14 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
this.lastOpenFilePath = lastOpenFilePath; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 获取西面板的上子面板的高度占容器总高度的比例 |
|
|
|
|
* 得到西面板的上下子面板的高度区分 |
|
|
|
|
* |
|
|
|
|
* @return |
|
|
|
|
*/ |
|
|
|
|
public double getLastWestRegionToolPaneYRate() { |
|
|
|
|
return westRegionToolPaneYRate; |
|
|
|
|
public int getLastWestRegionToolPaneY() { |
|
|
|
|
return this.westRegionToolPaneY; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
@ -458,11 +460,12 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 设置关闭设计器前,西面板的上子面板的高度占容器总高度的比例 |
|
|
|
|
* @param westRegionToolPaneYRate |
|
|
|
|
* 设置西面板的上下子面板的高度区分 |
|
|
|
|
* |
|
|
|
|
* @param toolPaneY |
|
|
|
|
*/ |
|
|
|
|
public void setLastWestRegionToolPaneYRate(double westRegionToolPaneYRate) { |
|
|
|
|
this.westRegionToolPaneYRate = westRegionToolPaneYRate; |
|
|
|
|
public void setLastWestRegionToolPaneY(int toolPaneY) { |
|
|
|
|
this.westRegionToolPaneY = toolPaneY; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
@ -526,7 +529,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
return env; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
String name = com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Workspace_Default"); |
|
|
|
|
String name = Toolkit.i18nText("Fine-Design_Basic_Workspace_Default"); |
|
|
|
|
LocalDesignerWorkspaceInfo newDefaultEnv = LocalDesignerWorkspaceInfo.create(name, defaultenvPath); |
|
|
|
|
this.putEnv(name, newDefaultEnv); |
|
|
|
|
return newDefaultEnv; |
|
|
|
@ -549,7 +552,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Workspace_Default"); |
|
|
|
|
return Toolkit.i18nText("Fine-Design_Basic_Workspace_Default"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -1607,8 +1610,8 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
|
|
|
|
|
private void readLastWestRegionLayout(XMLableReader reader) { |
|
|
|
|
String tmpVal; |
|
|
|
|
if ((tmpVal = reader.getAttrAsString("toolPaneYRate", null)) != null) { |
|
|
|
|
this.setLastWestRegionToolPaneYRate(Double.parseDouble(tmpVal)); |
|
|
|
|
if ((tmpVal = reader.getAttrAsString("toolPaneY", null)) != null) { |
|
|
|
|
this.setLastWestRegionToolPaneY(Integer.parseInt(tmpVal)); |
|
|
|
|
} |
|
|
|
|
if ((tmpVal = reader.getAttrAsString("containerWidth", null)) != null) { |
|
|
|
|
this.setLastWestRegionContainerWidth(Integer.parseInt(tmpVal)); |
|
|
|
@ -1640,7 +1643,7 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
if ((tmpVal = reader.getAttrAsString("webinfLocation", null)) != null) { |
|
|
|
|
// marks:兼容6.1的
|
|
|
|
|
// marks:设置默认的目录.
|
|
|
|
|
String curReportServerName = com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Server_Embedded_Server"); |
|
|
|
|
String curReportServerName = Toolkit.i18nText("Fine-Design_Basic_Server_Embedded_Server"); |
|
|
|
|
LocalDesignerWorkspaceInfo reportServer = LocalDesignerWorkspaceInfo.create(curReportServerName, tmpVal); |
|
|
|
|
|
|
|
|
|
this.putEnv(curReportServerName, reportServer); |
|
|
|
@ -1931,8 +1934,8 @@ public class DesignerEnvManager implements XMLReadable, XMLWriter {
|
|
|
|
|
|
|
|
|
|
private void writeLastWestRegionLayout(XMLPrintWriter writer) { |
|
|
|
|
writer.startTAG("LastWestRegionLayout"); |
|
|
|
|
if (this.getLastWestRegionToolPaneYRate() >= 0) { |
|
|
|
|
writer.attr("toolPaneYRate", this.getLastWestRegionToolPaneYRate()); |
|
|
|
|
if (this.getLastWestRegionToolPaneY() >= 0) { |
|
|
|
|
writer.attr("toolPaneY ", this.getLastWestRegionToolPaneY()); |
|
|
|
|
} |
|
|
|
|
if (this.getLastWestRegionContainerWidth() >= 0) { |
|
|
|
|
writer.attr("containerWidth", this.getLastWestRegionContainerWidth()); |
|
|
|
|