Browse Source

Pull request #5533: REPORT-57816 条件属性设置图片填充后,条件属性面板会立即消失

Merge in DESIGN/design from ~HENRY.WANG/design:release/10.0 to release/10.0

* commit '5adf17a73703d516c742926a44a0d5748b5937f5':
  REPORT-57816 REPORT-57816
zheng-1641779399395
Henry.Wang 3 years ago
parent
commit
74b4ce30a1
  1. 5
      designer-base/src/main/java/com/fr/design/gui/controlpane/UIControlPane.java
  2. 10
      designer-base/src/main/java/com/fr/design/gui/ifilechooser/JavaFxNativeFileChooser.java

5
designer-base/src/main/java/com/fr/design/gui/controlpane/UIControlPane.java

@ -3,6 +3,7 @@ package com.fr.design.gui.controlpane;
import com.fr.design.constants.UIConstants; import com.fr.design.constants.UIConstants;
import com.fr.design.dialog.FineJOptionPane; import com.fr.design.dialog.FineJOptionPane;
import com.fr.design.gui.controlpane.shortcutfactory.ShortCutFactory; import com.fr.design.gui.controlpane.shortcutfactory.ShortCutFactory;
import com.fr.design.gui.ifilechooser.JavaFxNativeFileChooser;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.gui.itoolbar.UIToolBarUI; import com.fr.design.gui.itoolbar.UIToolBarUI;
import com.fr.design.gui.itoolbar.UIToolbar; import com.fr.design.gui.itoolbar.UIToolbar;
@ -277,6 +278,10 @@ public abstract class UIControlPane extends JControlPane {
this.requestFocus(); this.requestFocus();
return; return;
} }
if (JavaFxNativeFileChooser.isShowDialogState()) {
JavaFxNativeFileChooser.setShowDialogState(false);
return;
}
saveSettings(); saveSettings();
setVisible(false); setVisible(false);
PopupDialogSaveAction saveAction = OSSupportCenter.getAction(PopupDialogSaveAction.class); PopupDialogSaveAction saveAction = OSSupportCenter.getAction(PopupDialogSaveAction.class);

10
designer-base/src/main/java/com/fr/design/gui/ifilechooser/JavaFxNativeFileChooser.java

@ -24,6 +24,7 @@ import java.util.List;
import java.util.concurrent.CountDownLatch; import java.util.concurrent.CountDownLatch;
public class JavaFxNativeFileChooser implements FileChooserProvider { public class JavaFxNativeFileChooser implements FileChooserProvider {
private static boolean showDialogState = false;
private File[] selectedFiles = new File[0]; private File[] selectedFiles = new File[0];
private FileSelectionMode fileSelectionMode = FileSelectionMode.FILE; private FileSelectionMode fileSelectionMode = FileSelectionMode.FILE;
private String title = Toolkit.i18nText("Fine-Design_Basic_Open"); private String title = Toolkit.i18nText("Fine-Design_Basic_Open");
@ -43,8 +44,17 @@ public class JavaFxNativeFileChooser implements FileChooserProvider {
return null; return null;
} }
public static boolean isShowDialogState() {
return showDialogState;
}
public static void setShowDialogState(boolean showDialogState) {
JavaFxNativeFileChooser.showDialogState = showDialogState;
}
@Override @Override
public int showDialog(Component parent) { public int showDialog(Component parent) {
setShowDialogState(true);
final CountDownLatch latch = new CountDownLatch(1); final CountDownLatch latch = new CountDownLatch(1);
PlatformImpl.startup(() -> { PlatformImpl.startup(() -> {
}); });

Loading…
Cancel
Save