Browse Source

Merge pull request #2892 in DESIGN/design from bugfix/10.0 to feature/10.0

* commit 'b1a142185932cfc65c33538180e284ad275058ee':
  REPORT-43022 【10.0.11冒烟】参数面板未进入的情况下撤销重做无效 【问题原因】参数面板的撤销重做并不是无效的,而是因为之前在不编辑参数面板的状态,如果经过了与参数面板有关的撤销重做操作,参数面板没有刷新 【改动方案】在没有编辑参数面板的时候,也需要populate一下参数面板
  REPORT-32205 设计器多屏使用问题
research/11.0
superman 4 years ago
parent
commit
0a51d2d6ed
  1. 8
      designer-base/src/main/java/com/fr/design/utils/gui/GUICoreUtils.java
  2. 5
      designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java

8
designer-base/src/main/java/com/fr/design/utils/gui/GUICoreUtils.java

@ -298,7 +298,11 @@ public final class GUICoreUtils {
* @param win the current window august:现在要考虑左边日志模板的影响 * @param win the current window august:现在要考虑左边日志模板的影响
*/ */
public static void centerWindow(Window win) { public static void centerWindow(Window win) {
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); // Toolkit.getDefaultToolkit().getScreenSize()在有多个显示器也只能获取到主屏的大小
// getGraphicsConfiguration().getBounds()能获取多个屏时 设计器主体界面所在屏的大小和对应的坐标
Rectangle rectangle = win.getGraphicsConfiguration().getBounds();
Dimension screenSize = rectangle.getSize();
Dimension winSize = win.getSize(); Dimension winSize = win.getSize();
@ -308,7 +312,7 @@ public final class GUICoreUtils {
if (winSize.width > screenSize.width) { if (winSize.width > screenSize.width) {
winSize.width = screenSize.width; winSize.width = screenSize.width;
} }
win.setLocation((screenSize.width - winSize.width) / 2, (screenSize.height - winSize.height) / 2 - WINDOW_GAP); win.setLocation(rectangle.x + (screenSize.width - winSize.width) / 2, rectangle.y + (screenSize.height - winSize.height) / 2 - WINDOW_GAP);
} }
/** /**

5
designer-realize/src/main/java/com/fr/design/mainframe/JWorkBook.java

@ -762,6 +762,11 @@ public class JWorkBook extends JTemplate<WorkBook, WorkBookUndoState> {
DesignModuleFactory.getFormHierarchyPane().refreshRoot(); DesignModuleFactory.getFormHierarchyPane().refreshRoot();
} }
} else { } else {
// REPORT-43022 即使没有处于编辑参数面板的状态,在经过有关参数面板的撤销后,也需要刷新一下参数面板
if (hasParameterPane()) {
parameterPane.populate(u.getApplyTarget());
setAutoHeightForCenterPane();
}
reportComposite.setSelectedIndex(u.getSelectedReportIndex()); reportComposite.setSelectedIndex(u.getSelectedReportIndex());
u.getSelectedEditingState().revert(); u.getSelectedEditingState().revert();
TableDataTreePane.getInstance(DesignModelAdapter.getCurrentModelAdapter()).refreshDockingView(); TableDataTreePane.getInstance(DesignModelAdapter.getCurrentModelAdapter()).refreshDockingView();

Loading…
Cancel
Save