Browse Source

REPORT-13303 设计器如果根目录有很多面板, 会卡在白屏很久, 不合理.

bugfix/10.0
Hades 6 years ago
parent
commit
9475d65d27
  1. 12
      designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java

12
designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java

@ -100,6 +100,8 @@ import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Set;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
public class DesignerFrame extends JFrame implements JTemplateActionListener, TargetModifiedListener {
@ -247,6 +249,9 @@ public class DesignerFrame extends JFrame implements JTemplateActionListener, Ta
private ProgressDialog progressDialog;
private ExecutorService fixedThreadPool = Executors.newFixedThreadPool(1);
public DesignerFrame(ToolBarMenuDock ad) {
setName(DESIGNER_FRAME_NAME);
@ -809,19 +814,22 @@ public class DesignerFrame extends JFrame implements JTemplateActionListener, Ta
* 报表运行环境改变时,需要刷新某些面板
*/
public void refreshEnv() {
this.setTitle();
fixedThreadPool.execute(new Runnable() {
@Override
public void run() {
DesignerFrameFileDealerPane.getInstance().refreshDockingView();
TableDataTreePane.getInstance(DesignModelAdapter.getCurrentModelAdapter());
TemplateTreePane.getInstance().refreshDockingView();
DesignTableDataManager.clearGlobalDs();
EastRegionContainerPane.getInstance().refreshDownPane();
JTemplate template = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate();
if (template != null) {
template.refreshToolArea();
}
}
});
}
/**
* 返回选中的模板.

Loading…
Cancel
Save