From a821024929f83bde6ee045b69f957359aa69bf18 Mon Sep 17 00:00:00 2001 From: hades Date: Fri, 23 Jul 2021 15:45:26 +0800 Subject: [PATCH] =?UTF-8?q?REPORT-55228=20=E5=B7=A5=E5=85=B7=E6=A0=8F?= =?UTF-8?q?=E9=97=AE=E9=A2=98=20=20&&=20REPORT-55228=20=E8=AE=BE=E8=AE=A1?= =?UTF-8?q?=E5=99=A8=E5=90=AF=E5=8A=A8=E5=BC=95=E5=AF=BC=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E4=B8=8E=E5=88=87=E6=8D=A2=E8=B4=A6=E5=8F=B7=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=20=E4=B9=9F=E8=A6=81=E6=8F=90=E7=A4=BA"=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E7=9B=B8=E5=85=B3=E7=BB=84=E4=BB=B6"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/fr/design/login/DesignerLoginHelper.java | 4 +++- .../com/fr/design/login/DesignerLoginShowDialog.java | 2 ++ .../com/fr/design/login/guide/DesignerGuideHelper.java | 2 +- .../java/com/fr/design/designer/creator/XCreator.java | 10 +++++++++- .../com/fr/design/mainframe/EditingMouseListener.java | 2 +- 5 files changed, 16 insertions(+), 4 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/login/DesignerLoginHelper.java b/designer-base/src/main/java/com/fr/design/login/DesignerLoginHelper.java index 5da006fa76..2d2dd935d1 100644 --- a/designer-base/src/main/java/com/fr/design/login/DesignerLoginHelper.java +++ b/designer-base/src/main/java/com/fr/design/login/DesignerLoginHelper.java @@ -6,6 +6,7 @@ import com.fr.design.extra.WebViewDlgHelper; import com.fr.design.i18n.Toolkit; import com.fr.design.mainframe.DesignerContext; import com.fr.design.os.impl.SupportOSImpl; +import com.fr.design.plugin.DesignerPluginContext; import com.fr.design.update.ui.dialog.UpdateMainDialog; import com.fr.general.GeneralContext; import java.awt.Dialog; @@ -25,7 +26,7 @@ import javax.swing.WindowConstants; public class DesignerLoginHelper { private static final String MAIN_RESOURCE_PATH = "/com/fr/design/login/login.html"; - private static final String JXBROWSER = "com.teamdev.jxbrowser.chromium.Browser"; + private static final String JXBROWSER = "com.teamdev.jxbrowser.browser.Browser"; private static UIDialog dialog = null; @@ -91,6 +92,7 @@ public class DesignerLoginHelper { dialog.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); dialog.setVisible(false); dialog = null; + DesignerPluginContext.setPluginDialog(null); } } diff --git a/designer-base/src/main/java/com/fr/design/login/DesignerLoginShowDialog.java b/designer-base/src/main/java/com/fr/design/login/DesignerLoginShowDialog.java index 031ec4941f..53e4556e4e 100644 --- a/designer-base/src/main/java/com/fr/design/login/DesignerLoginShowDialog.java +++ b/designer-base/src/main/java/com/fr/design/login/DesignerLoginShowDialog.java @@ -1,6 +1,7 @@ package com.fr.design.login; import com.fr.design.dialog.UIDialog; +import com.fr.design.plugin.DesignerPluginContext; import com.fr.design.utils.gui.GUICoreUtils; import java.awt.BorderLayout; import java.awt.Component; @@ -36,6 +37,7 @@ public class DesignerLoginShowDialog extends UIDialog { setSize(DEFAULT); GUICoreUtils.centerWindow(this); setResizable(false); + DesignerPluginContext.setPluginDialog(this); } @Override diff --git a/designer-base/src/main/java/com/fr/design/login/guide/DesignerGuideHelper.java b/designer-base/src/main/java/com/fr/design/login/guide/DesignerGuideHelper.java index 92e4171460..b3513bb6da 100644 --- a/designer-base/src/main/java/com/fr/design/login/guide/DesignerGuideHelper.java +++ b/designer-base/src/main/java/com/fr/design/login/guide/DesignerGuideHelper.java @@ -22,7 +22,7 @@ import javax.swing.WindowConstants; public class DesignerGuideHelper { private static final String MAIN_RESOURCE_PATH = "/com/fr/design/login/guide.html"; - private static final String JXBROWSER = "com.teamdev.jxbrowser.chromium.Browser"; + private static final String JXBROWSER = "com.teamdev.jxbrowser.browser.Browser"; private static final long ONE_WEEK = 7 * 24 * 3600 * 1000L; private static final long ONE_MONTH = 30 * 24 * 3600 * 1000L; private static final long SIX_MONTH = 6 * ONE_MONTH; diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java index 185c834f75..dbc956c857 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreator.java @@ -23,6 +23,7 @@ import com.fr.design.mainframe.EditingMouseListener; import com.fr.design.mainframe.FormDesigner; import com.fr.design.mainframe.NoSupportAuthorityEdit; import com.fr.design.mainframe.WidgetPropertyPane; +import com.fr.design.plugin.DesignerPluginContext; import com.fr.design.utils.gui.LayoutUtils; import com.fr.form.ui.Widget; import com.fr.form.ui.container.WTitleLayout; @@ -783,12 +784,19 @@ public abstract class XCreator extends JPanel implements XComponent, XCreatorToo public void run() { popup.setLocation(designer.getLocationOnScreen().x + designer.getPaintX() + extraX, designer.getLocationOnScreen().y + designer.getPaintY() + extraY); popup.updatePane(designer); - popup.setVisible(selected && accept && popup.hasVisibleButtons() && popup.isCanVisible()); + popup.setVisible(selected && accept && popup.hasVisibleButtons() && popup.isCanVisible() && !isShowPluginDialog()); popup.setRelativeBounds(bounds); } }); } + private boolean isShowPluginDialog() { + if (DesignerPluginContext.getPluginDialog() == null) { + return false; + } + return DesignerPluginContext.getPluginDialog().isVisible(); + } + /** * 创建右击弹出菜单 * diff --git a/designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java b/designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java index 5cd0458350..c1d834fa94 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/EditingMouseListener.java @@ -647,7 +647,7 @@ public class EditingMouseListener extends MouseInputAdapter { @Override public void run() { for (XCreator xCreator : xCreators) { - xCreator.setSelected(true); + xCreator.setSelected(!e.isShiftDown()); } } });