From 1a8a38a8893a4c070afe9d1672c20950e1179e9a Mon Sep 17 00:00:00 2001 From: kerry Date: Wed, 24 Nov 2021 15:33:22 +0800 Subject: [PATCH 1/9] =?UTF-8?q?REPORT-63190=E3=80=90=E6=8E=A5=E8=A7=A6?= =?UTF-8?q?=E7=82=B9=E4=BC=98=E5=8C=96=E3=80=91=E8=BD=AE=E6=92=AD=E8=BF=87?= =?UTF-8?q?=E7=A8=8B=E4=B8=AD=E5=88=87=E6=8D=A2=E7=BB=84=E4=BB=B6=E5=8C=85?= =?UTF-8?q?=EF=BC=8C=E5=86=8D=E5=9B=9E=E6=9D=A5=E5=8F=91=E7=8E=B0=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E6=9C=89=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../share/ui/block/AbstractOnlineWidgetBlock.java | 4 ++++ .../share/ui/block/OnlineWidgetPackageBlock.java | 3 +++ .../mainframe/share/ui/block/PreviewWidgetBlock.java | 7 ++++++- .../mainframe/share/ui/block/SimpleWidgetBlock.java | 5 +++++ .../ui/online/AbstractOnlineWidgetSelectPane.java | 2 +- .../ui/online/resource/OnlineResourceManager.java | 10 ++++++++-- .../share/ui/online/resource/ResourceLoader.java | 7 +++++++ 7 files changed, 34 insertions(+), 4 deletions(-) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java index 582f353ee..864e5cdda 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java @@ -95,6 +95,10 @@ public abstract class AbstractOnlineWidgetBlock extends PreviewWidgetBlock extends JPanel implements MouseListe @Override public void mouseEntered(MouseEvent e) { hover = true; - if (ComponentShareUtil.needShowFirstDragAnimate() && !FormWidgetDetailPane.getInstance().hasTouched() && checkWidget()) { + if (ComponentShareUtil.needShowFirstDragAnimate() && supportFirstDragAnimate() && + !FormWidgetDetailPane.getInstance().hasTouched() && checkWidget()) { schedule(ANIMATE_START_TIME); awtEventListener = event -> { if (!this.isShowing()) { @@ -169,6 +170,10 @@ public abstract class PreviewWidgetBlock extends JPanel implements MouseListe } } + protected boolean supportFirstDragAnimate(){ + return true; + } + protected boolean checkWidget() { return true; } diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/SimpleWidgetBlock.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/SimpleWidgetBlock.java index cf5e948de..a76220fd5 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/SimpleWidgetBlock.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/SimpleWidgetBlock.java @@ -14,4 +14,9 @@ public class SimpleWidgetBlock extends OnlineWidgetBlock { this.removeListener(); this.setFocusable(false); } + + protected boolean supportFirstDragAnimate(){ + return false; + } + } diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetSelectPane.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetSelectPane.java index 53239700d..187bcca32 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetSelectPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/AbstractOnlineWidgetSelectPane.java @@ -170,7 +170,7 @@ public abstract class AbstractOnlineWidgetSelectPane extends AbstractWidgetSele if (!OnlineShopUtils.testConnection()) { return OnlineWidgetSelectPane.PaneStatue.DISCONNECTED; } - OnlineResourceManager.getInstance().cancelLoad(); + OnlineResourceManager.getInstance().cancelLoad(this); contentPane.removeAll(); scrollPane = createScrollPane(); diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/OnlineResourceManager.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/OnlineResourceManager.java index 4e10ff25b..b29ea11db 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/OnlineResourceManager.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/OnlineResourceManager.java @@ -3,6 +3,7 @@ package com.fr.design.mainframe.share.ui.online.resource; import javax.swing.SwingWorker; import java.util.concurrent.ArrayBlockingQueue; import java.util.concurrent.BlockingQueue; +import java.util.function.Predicate; /** * Created by kerry on 2020-12-10 @@ -25,11 +26,16 @@ public class OnlineResourceManager { private final BlockingQueue loaderBlockingQueue = new ArrayBlockingQueue(100); - public void cancelLoad() { + public void cancelLoad(Object key) { if (swingWorker != null) { swingWorker.cancel(true); } - this.loaderBlockingQueue.clear(); + loaderBlockingQueue.removeIf(new Predicate() { + @Override + public boolean test(ResourceLoader resourceLoader) { + return resourceLoader.checkValid(key); + } + }); } public void addLoader(ResourceLoader loader) { diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/ResourceLoader.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/ResourceLoader.java index fee705f8a..7aacd2941 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/ResourceLoader.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/resource/ResourceLoader.java @@ -10,4 +10,11 @@ public interface ResourceLoader { */ void load(); + /** + * 检查resource是否属于某分类 + * @param key 分类标识 + * @return boolean + */ + boolean checkValid(Object key); + } From 23ece8197e7460b3d0b94a774b8f391bdfafdf02 Mon Sep 17 00:00:00 2001 From: Starryi Date: Wed, 24 Nov 2021 15:00:35 +0800 Subject: [PATCH 2/9] =?UTF-8?q?REPORT-63250=20=E7=BB=84=E4=BB=B6=E5=8F=AF?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E8=A7=86=E8=A7=89=E9=AA=8C=E6=94=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 【问题原因】 修改设计器组件商城面板上一些控件的展示效果 【改动思路】 同上 --- .../design/mainframe/share/ui/local/LocalWidgetRepoPane.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/local/LocalWidgetRepoPane.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/local/LocalWidgetRepoPane.java index fd050513b..0d0cff570 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/local/LocalWidgetRepoPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/local/LocalWidgetRepoPane.java @@ -119,10 +119,12 @@ public class LocalWidgetRepoPane extends BasicPane { content.add(LabelUtils.createAutoWrapLabel(Toolkit.i18nText("Fine-Design_Share_Upgrade_Tip"), new Color(0x333334)), BorderLayout.CENTER); JPanel actionsPane = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 0)); + actionsPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, -5)); actionsPane.setOpaque(false); actionsPane.setBackground(null); UIButton cancelUpgradeButton = new UIButton(Toolkit.i18nText("Fine-Design_Share_Upgrade_Cancel")); + cancelUpgradeButton.setRoundBorder(true); cancelUpgradeButton.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { @@ -132,6 +134,8 @@ public class LocalWidgetRepoPane extends BasicPane { UIButton startUpgradeButton = new UIButton(Toolkit.i18nText("Fine-Design_Share_Upgrade_All")); startUpgradeButton.setSelected(true); + startUpgradeButton.setRoundBorder(true); + startUpgradeButton.setBorderPainted(false); startUpgradeButton.setForeground(Color.WHITE); startUpgradeButton.addActionListener(new ActionListener() { @Override From 6aa636185daf0bf2a471b433891590b4195ff47b Mon Sep 17 00:00:00 2001 From: kerry Date: Wed, 24 Nov 2021 17:26:52 +0800 Subject: [PATCH 3/9] =?UTF-8?q?REPORT-62672=E3=80=90=E6=8E=A5=E8=A7=A6?= =?UTF-8?q?=E7=82=B9=E4=BC=98=E5=8C=96=E3=80=91=E9=83=A8=E5=88=86=E5=9F=8B?= =?UTF-8?q?=E7=82=B9=E6=97=A0=E6=B3=95=E6=A8=A1=E6=8B=9F=E5=AF=B9=E5=BA=94?= =?UTF-8?q?=E5=9F=8B=E7=82=B9=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fr/design/mainframe/share/collect/ComponentCollector.java | 3 --- .../share/ui/online/embed/OnlineEmbedFilterSelectPane.java | 3 ++- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java b/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java index db9fbe43b..d65f6af9a 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java @@ -343,9 +343,6 @@ public class ComponentCollector implements XMLable { } public void clickComponentSetting() { - if (!ComponentShareUtil.needShowEmbedFilterPane()) { - return; - } boolean changed = false; int firstShowReact = ComponentReuseNotificationInfo.getInstance().isWidgetLibHasRefreshed() ? 2 : -1; if (this.firstShowReact != firstShowReact) { diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java index 3f4cea2a0..be433aa56 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java @@ -40,6 +40,7 @@ public class OnlineEmbedFilterSelectPane extends AbstractOnlineWidgetSelectPane private static final String CAROUSEL_PREVIEW = "carousel_preview"; private static final int CAROUSE_IMAGE_LOAD_TIMEOUT = 2000; private OnlineShareWidget[] showWidgets; + private static final int NOT_CAROUSE_WIDGET_NUM = 30; private PreviewDialog previewDialog; private JPanel widgetPane; @@ -144,7 +145,7 @@ public class OnlineEmbedFilterSelectPane extends AbstractOnlineWidgetSelectPane stopCarouse(integer); return; } - if (integer.get() == 0) { + if (integer.get() == NOT_CAROUSE_WIDGET_NUM) { CarouselStateManger.getInstance().stop(); stopCarouse(integer); previewDialog.setVisible(false); From 0c77e8cdf3f2f8c0c9a84e7ad6ef2f409919e91c Mon Sep 17 00:00:00 2001 From: Hoky <303455184@qq.com> Date: Wed, 24 Nov 2021 17:41:04 +0800 Subject: [PATCH 4/9] =?UTF-8?q?REPORT-63196=20&&=20REPORT-63186=201.?= =?UTF-8?q?=E5=9C=A8=E5=8F=8C=E5=87=BB=E4=B9=8B=E5=90=8E=E4=BD=BF=E6=90=9C?= =?UTF-8?q?=E7=B4=A2=E6=A1=86=E6=B6=88=E5=A4=B1=EF=BC=9B=202.=E6=A8=A1?= =?UTF-8?q?=E6=8B=9F=E8=AE=A1=E7=AE=97=E5=9C=A8=E8=AE=A1=E7=AE=97=E9=94=99?= =?UTF-8?q?=E8=AF=AF=E7=9A=84=E6=97=B6=E5=80=99=E6=8F=90=E7=A4=BA=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/formula/FormulaPane.java | 24 +++++++++++++------ 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/formula/FormulaPane.java b/designer-base/src/main/java/com/fr/design/formula/FormulaPane.java index b11644e68..dc1e03027 100644 --- a/designer-base/src/main/java/com/fr/design/formula/FormulaPane.java +++ b/designer-base/src/main/java/com/fr/design/formula/FormulaPane.java @@ -46,6 +46,7 @@ import com.fr.parser.BlockIntervalLiteral; import com.fr.parser.ColumnRowRangeInPage; import com.fr.parser.NumberLiteral; import com.fr.parser.SheetIntervalLiteral; +import com.fr.record.analyzer.EnableMetrics; import com.fr.report.core.namespace.SimpleCellValueNameSpace; import com.fr.script.Calculator; import com.fr.script.ScriptConstants; @@ -54,7 +55,6 @@ import com.fr.stable.EncodeConstants; import com.fr.stable.EssentialUtils; import com.fr.stable.ParameterProvider; import com.fr.stable.StringUtils; -import com.fr.stable.UtilEvalError; import com.fr.stable.script.CRAddress; import com.fr.stable.script.ColumnRowRange; import com.fr.stable.script.Expression; @@ -122,6 +122,7 @@ import java.util.Set; * @editor zhou * @since 2012-3-29下午1:50:53 */ +@EnableMetrics public class FormulaPane extends BasicPane implements KeyListener, UIFormula { public static final int DEFUAL_FOMULA_LENGTH = 103; public static final String ELLIPSIS = "..."; @@ -139,6 +140,7 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula { protected static UICheckBox autoCompletionCheck; protected static UICheckBox checkBeforeColse; private JList tipsList; + private JPopupMenu popupMenu; protected DefaultListModel listModel = new DefaultListModel(); private int ifHasBeenWriten = 0; private DefaultListModel functionTypeListModel = new DefaultListModel(); @@ -457,6 +459,9 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula { if (ComparatorUtils.equals((String) listModel.getElementAt(index), doublePressContent)) { doubleClickActuator(doublePressContent); } + if (popupMenu != null) { + popupMenu.setVisible(false); + } } } } @@ -616,7 +621,7 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula { } private void popTips() { - JPopupMenu popupMenu = new JPopupMenu(); + popupMenu = new JPopupMenu(); JScrollPane tipsScrollPane = new JScrollPane(tipsList); popupMenu.add(tipsScrollPane); tipsScrollPane.setPreferredSize(new Dimension(240, 146)); @@ -792,6 +797,7 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula { private final ActionListener calculateActionListener = new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { String formulaText = formulaTextArea.getText().trim(); @@ -819,16 +825,20 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula { } BaseFormula baseFormula = BaseFormula.createFormulaBuilder().build(formulaText); + Object calResult; try { - Object value = calculator.evalValue(baseFormula); - String objectToString = EssentialUtils.objectToString(value); + calResult = calculator.evalValue(baseFormula); + String objectToString = EssentialUtils.objectToString(calResult); String result = objectToString.length() > DEFUAL_FOMULA_LENGTH ? objectToString.substring(0, DEFUAL_FOMULA_LENGTH - ELLIPSIS.length()) + ELLIPSIS : objectToString; messageTips = messageTips + Toolkit.i18nText("Fine-Design_Basic_Formula_Cal_Result") + ":" + result; - FineLoggerFactory.getLogger().info("value:{}", value); - } catch (UtilEvalError utilEvalError) { - FineLoggerFactory.getLogger().error(utilEvalError.getMessage(), utilEvalError); + } catch (Exception ce) { + //模拟计算如果出现错误,则抛出错误 + calResult = ce.getMessage(); + FineLoggerFactory.getLogger().error(ce.getMessage(), ce); + messageTips = messageTips + Toolkit.i18nText("Fine-Design_Basic_Formula_Cal_Error") + ":" + calResult; } + FineLoggerFactory.getLogger().info("value:{}", calResult); } else { messageTips = checkResult.getTips(); } From 568cf34dc65fa13e4efe4d2f2ab8c377732c7827 Mon Sep 17 00:00:00 2001 From: hades Date: Wed, 24 Nov 2021 18:37:02 +0800 Subject: [PATCH 5/9] =?UTF-8?q?REPORT-63305=20=E8=AE=BE=E8=AE=A1=E5=99=A8?= =?UTF-8?q?=E8=8E=B7=E5=8F=96=E7=88=B6=E5=AE=B9=E5=99=A8=EF=BC=8C=E9=9C=80?= =?UTF-8?q?=E8=A6=81=E5=AF=B9=E6=8B=93=E5=B1=95=E7=9A=84=E5=B8=83=E5=B1=80?= =?UTF-8?q?=E6=8F=92=E4=BB=B6=E5=85=BC=E5=AE=B9=E5=A4=84=E7=90=86=E4=B8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../designer/creator/XCreatorUtils.java | 26 +++++++++++++++++++ .../widget/ui/FormSingleWidgetCardPane.java | 7 ++--- .../designer/component/WidgetBoundPane.java | 10 ++----- 3 files changed, 30 insertions(+), 13 deletions(-) diff --git a/designer-form/src/main/java/com/fr/design/designer/creator/XCreatorUtils.java b/designer-form/src/main/java/com/fr/design/designer/creator/XCreatorUtils.java index 2f797efa4..6445e001b 100644 --- a/designer-form/src/main/java/com/fr/design/designer/creator/XCreatorUtils.java +++ b/designer-form/src/main/java/com/fr/design/designer/creator/XCreatorUtils.java @@ -57,6 +57,7 @@ import com.fr.form.ui.container.cardlayout.WCardMainBorderLayout; import com.fr.form.ui.container.cardlayout.WCardTagLayout; import com.fr.form.ui.container.cardlayout.WCardTitleLayout; import com.fr.form.ui.container.cardlayout.WTabFitLayout; +import com.fr.general.ComparatorUtils; import com.fr.general.GeneralContext; import com.fr.general.IOUtils; import com.fr.invoke.Reflect; @@ -68,6 +69,7 @@ import com.fr.plugin.observer.PluginEvent; import com.fr.plugin.observer.PluginEventListener; import com.fr.stable.StringUtils; import com.fr.third.javax.annotation.Nonnull; +import java.util.Set; import org.jetbrains.annotations.Nullable; import javax.swing.Icon; @@ -375,4 +377,28 @@ public class XCreatorUtils { return xCreator; } + + public static boolean isExtraContainer(XCreator creator) { + Set set = ExtraDesignClassManager.getInstance().getArray(FormWidgetOptionProvider.XML_TAG); + for (FormWidgetOptionProvider provider : set) { + if (provider.isContainer() + && ComparatorUtils.equals(provider.appearanceForWidget(), provider.appearanceForWidget()) + && ComparatorUtils.equals(provider.classForWidget(), creator.toData().getClass())) { + return true; + } + } + return false; + } + + public static XLayoutContainer getParent(XCreator source) { + if (source.acceptType(XWCardTagLayout.class) ) { + return (XLayoutContainer)source.getParent(); + } + XLayoutContainer container = XCreatorUtils.getParentXLayoutContainer(source); + boolean accept = (source.acceptType(XWFitLayout.class) || source.acceptType(XWParameterLayout.class)) && !isExtraContainer(source); + if (accept) { + container = null; + } + return container; + } } \ No newline at end of file diff --git a/designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormSingleWidgetCardPane.java b/designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormSingleWidgetCardPane.java index 1fd1a3527..491b42b2b 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormSingleWidgetCardPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormSingleWidgetCardPane.java @@ -67,12 +67,9 @@ public class FormSingleWidgetCardPane extends FormWidgetCardPane { initDefinePane(); } + @Deprecated public XLayoutContainer getParent(XCreator source) { - XLayoutContainer container = XCreatorUtils.getParentXLayoutContainer(source); - if (source.acceptType(XWFitLayout.class) || source.acceptType(XWParameterLayout.class)) { - container = null; - } - return container; + return XCreatorUtils.getParent(source); } public WidgetBoundPane createWidgetBoundPane(XCreator xCreator) { diff --git a/designer-form/src/main/java/com/fr/design/widget/ui/designer/component/WidgetBoundPane.java b/designer-form/src/main/java/com/fr/design/widget/ui/designer/component/WidgetBoundPane.java index aee83889e..f711eb157 100644 --- a/designer-form/src/main/java/com/fr/design/widget/ui/designer/component/WidgetBoundPane.java +++ b/designer-form/src/main/java/com/fr/design/widget/ui/designer/component/WidgetBoundPane.java @@ -61,15 +61,9 @@ public class WidgetBoundPane extends BasicPane { initBoundPane(); } + @Deprecated public XLayoutContainer getParent(XCreator source) { - if(source.acceptType(XWCardTagLayout.class)){ - return (XLayoutContainer)source.getParent(); - } - XLayoutContainer container = XCreatorUtils.getParentXLayoutContainer(source); - if (source.acceptType(XWFitLayout.class) || source.acceptType(XWParameterLayout.class)) { - container = null; - } - return container; + return XCreatorUtils.getParent(source); } public void initBoundPane() { From 8de9339eceaf774fe0f497b6845a82daa8b98762 Mon Sep 17 00:00:00 2001 From: hades Date: Thu, 25 Nov 2021 11:37:08 +0800 Subject: [PATCH 6/9] =?UTF-8?q?CHART-22038=20=E5=86=B3=E7=AD=96=E6=8A=A5?= =?UTF-8?q?=E8=A1=A8=EF=BC=8C=E5=AE=89=E8=A3=85ECharts=E5=90=8E=EF=BC=8C?= =?UTF-8?q?=E5=9B=BE=E8=A1=A8=E5=9D=97=E6=8F=92=E5=85=A5=E5=9B=BE=E8=A1=A8?= =?UTF-8?q?=E5=8C=BA=E5=9F=9F=E4=B8=8D=E6=98=BE=E7=A4=BAecharts=E7=9A=84?= =?UTF-8?q?=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/mainframe/FormParaWidgetPane.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/FormParaWidgetPane.java b/designer-form/src/main/java/com/fr/design/mainframe/FormParaWidgetPane.java index 09e02ac67..be752777b 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/FormParaWidgetPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/FormParaWidgetPane.java @@ -7,6 +7,7 @@ import com.fr.design.constants.UIConstants; import com.fr.design.designer.beans.events.DesignerEditListener; import com.fr.design.designer.beans.events.DesignerEvent; import com.fr.design.designer.creator.XCreatorUtils; +import com.fr.design.file.HistoryTemplateListCache; import com.fr.design.fun.FormWidgetOptionProvider; import com.fr.design.gui.chart.ChartXMLTag; import com.fr.design.gui.core.FormWidgetOption; @@ -19,6 +20,7 @@ import com.fr.design.gui.imenu.UIPopupMenu; import com.fr.design.i18n.Toolkit; import com.fr.design.mainframe.share.collect.ComponentCollector; import com.fr.design.module.DesignModuleFactory; +import com.fr.design.ui.util.UIUtil; import com.fr.design.utils.gui.LayoutUtils; import com.fr.form.ui.UserDefinedWidgetConfig; import com.fr.form.ui.Widget; @@ -99,6 +101,15 @@ public class FormParaWidgetPane extends JPanel { synchronized (FormParaWidgetPane.class) { THIS = null; } + UIUtil.invokeLaterIfNeeded(new Runnable() { + @Override + public void run() { + JTemplate template = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); + if (template != null && !template.isJWorkBook()) { + DesignerContext.getDesignerFrame().resetToolkitByPlus(template); + } + } + }); } }, new PluginFilter() { From 76b1cc1e02ccf6e042d65b4872ddac265e1a1660 Mon Sep 17 00:00:00 2001 From: kerry Date: Thu, 25 Nov 2021 15:43:32 +0800 Subject: [PATCH 7/9] =?UTF-8?q?REPORT-63308=E3=80=90=E6=8E=A5=E8=A7=A6?= =?UTF-8?q?=E7=82=B9=E4=BC=98=E5=8C=96=E3=80=91=E8=BD=AE=E6=92=AD=E6=9C=9F?= =?UTF-8?q?=E9=97=B4=E5=9C=A8=E7=BB=84=E4=BB=B6=E4=B8=8A=E5=8F=B3=E9=94=AE?= =?UTF-8?q?=E7=9A=84=E4=BA=A4=E4=BA=92=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mainframe/share/ui/block/AbstractOnlineWidgetBlock.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java index 864e5cdda..5c1620ab4 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/block/AbstractOnlineWidgetBlock.java @@ -114,7 +114,7 @@ public abstract class AbstractOnlineWidgetBlock extends PreviewWidgetBlock Date: Thu, 25 Nov 2021 17:21:25 +0800 Subject: [PATCH 8/9] =?UTF-8?q?REPORT-62672=E3=80=90=E6=8E=A5=E8=A7=A6?= =?UTF-8?q?=E7=82=B9=E4=BC=98=E5=8C=96=E3=80=91=E9=83=A8=E5=88=86=E5=9F=8B?= =?UTF-8?q?=E7=82=B9=E6=97=A0=E6=B3=95=E6=A8=A1=E6=8B=9F=E5=AF=B9=E5=BA=94?= =?UTF-8?q?=E5=9F=8B=E7=82=B9=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../share/collect/ComponentCollector.java | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java b/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java index d65f6af9a..477673978 100644 --- a/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java +++ b/designer-base/src/main/java/com/fr/design/mainframe/share/collect/ComponentCollector.java @@ -343,18 +343,12 @@ public class ComponentCollector implements XMLable { } public void clickComponentSetting() { - boolean changed = false; int firstShowReact = ComponentReuseNotificationInfo.getInstance().isWidgetLibHasRefreshed() ? 2 : -1; if (this.firstShowReact != firstShowReact) { - this.firstShowReact = firstShowReact; - changed = true; + collectFirstShowReact(firstShowReact); } if (this.embededFilterReact == 0 && ComponentReuseNotificationInfo.getInstance().isWidgetLibHasRefreshed()) { - this.embededFilterReact = -1; - changed = true; - } - if (changed) { - saveInfo(); + collectEmbededFilterReact(-1); } } @@ -371,11 +365,16 @@ public class ComponentCollector implements XMLable { return; } if (System.currentTimeMillis() - ComponentReuseNotificationInfo.getInstance().getFirstDragEndTime() <= ONE_MINUTE) { - this.dynamicEffectReact = 1; - saveInfo(); + collectDynamicEffectReactFlag(1); } } + public void collectDynamicEffectReactFlag(int flag) { + this.dynamicEffectReact = flag; + saveInfo(); + } + + public void clearSortType() { sortType = JSONFactory.createJSON(JSON.ARRAY); } From 4818c71faef81099ff01127d0d9e788827a6ed84 Mon Sep 17 00:00:00 2001 From: kerry Date: Thu, 25 Nov 2021 18:40:40 +0800 Subject: [PATCH 9/9] =?UTF-8?q?REPORT-63311=E3=80=90=E6=8E=A5=E8=A7=A6?= =?UTF-8?q?=E7=82=B9=E4=BC=98=E5=8C=96=E3=80=91=E8=BD=AE=E6=92=AD=E6=9C=9F?= =?UTF-8?q?=E9=97=B4=E5=88=87=E6=8D=A2=E7=BB=84=E4=BB=B6=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=EF=BC=8C=E8=BD=AE=E6=92=AD=E5=81=9C=E4=BD=8F?= =?UTF-8?q?=E4=BA=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ui/online/embed/OnlineEmbedFilterSelectPane.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java index be433aa56..def1056e9 100644 --- a/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java +++ b/designer-form/src/main/java/com/fr/design/mainframe/share/ui/online/embed/OnlineEmbedFilterSelectPane.java @@ -57,8 +57,7 @@ public class OnlineEmbedFilterSelectPane extends AbstractOnlineWidgetSelectPane Point selectPanePoint = OnlineEmbedFilterSelectPane.this.getLocationOnScreen(); Dimension selectPaneDimension = OnlineEmbedFilterSelectPane.this.getSize(); Rectangle selectPaneRec = new Rectangle(selectPanePoint.x, selectPanePoint.y, selectPaneDimension.width, selectPaneDimension.height); - if (CarouselStateManger.getInstance().running() && - !selectPaneRec.contains(((MouseEvent) event).getLocationOnScreen())) { + if (!selectPaneRec.contains(((MouseEvent) event).getLocationOnScreen())) { CarouselStateManger.getInstance().stop(); } } catch (Exception e) { @@ -173,6 +172,12 @@ public class OnlineEmbedFilterSelectPane extends AbstractOnlineWidgetSelectPane } if (!CarouselStateManger.getInstance().isSuspend()) { previewDialog.setVisible(true); + //再做一次检查,避免因并发导致的previewDialog始终展示的问题 + if (CarouselStateManger.getInstance().stopped()) { + stopCarouse(integer); + service.shutdown(); + return; + } showCurrentLoadBlock(integer, widgetPane); service.shutdown(); }