Browse Source

Merge pull request #706 in DESIGN/design from ~HADES/design:release/10.0 to release/10.0

* commit '80707b0c5264ff5fe138f3275ea4545f41eb255e':
  REPORT-13303 设计器如果根目录有很多面板, 会卡在白屏很久, 不合理.
bugfix/10.0
Hades 6 years ago
parent
commit
5c937198fa
  1. 30
      designer-base/src/main/java/com/fr/design/mainframe/DesignerFrame.java

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

@ -102,6 +102,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 {
@ -241,6 +243,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);
@ -815,18 +820,21 @@ public class DesignerFrame extends JFrame implements JTemplateActionListener, Ta
* 报表运行环境改变时,需要刷新某些面板
*/
public void refreshEnv() {
this.setTitle();
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();
}
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