From 43609c951816cf5bfee0365556990fc1640c3735 Mon Sep 17 00:00:00 2001 From: Lanlan Date: Tue, 24 Dec 2019 16:30:18 +0800 Subject: [PATCH 1/2] =?UTF-8?q?REPORT-24689=20=E8=AE=BE=E8=AE=A1=E5=99=A8?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=9A=84=E6=8E=A8=E9=80=81=E5=BC=B9=E7=AA=97?= =?UTF-8?q?=E5=85=B3=E9=97=AD=E6=8C=89=E9=92=AE=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/com/fr/design/ui/update/push/pushUpdate.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/designer-base/src/main/resources/com/fr/design/ui/update/push/pushUpdate.js b/designer-base/src/main/resources/com/fr/design/ui/update/push/pushUpdate.js index f42fb1ac7b..d1c46cee2a 100644 --- a/designer-base/src/main/resources/com/fr/design/ui/update/push/pushUpdate.js +++ b/designer-base/src/main/resources/com/fr/design/ui/update/push/pushUpdate.js @@ -104,8 +104,7 @@ function getMoreInfo() { function getCloseButton() { return BI.createWidget({ type: "bi.button", - text: "", - iconCls: "close-font", + text: String.fromCharCode(10005), cls: "close-btn", clear: true, handler: function () { From 4be4bc6e80449c8597cfbc37ab447dcfc0d78ef4 Mon Sep 17 00:00:00 2001 From: Lanlan Date: Wed, 25 Dec 2019 11:28:36 +0800 Subject: [PATCH 2/2] =?UTF-8?q?REPORT-25522=20=E4=BF=AE=E6=94=B9=E8=AE=BE?= =?UTF-8?q?=E8=AE=A1=E5=99=A8=E7=9A=84=E6=97=A5=E6=9C=9F=E5=90=8E=EF=BC=8C?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=8E=A8=E9=80=81=E6=B6=88=E6=81=AF=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E5=BC=B9=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../push/DesignerPushUpdateManager.java | 22 +++++++++---------- .../fr/start/module/DesignerActivator.java | 10 +++++++++ 2 files changed, 21 insertions(+), 11 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java b/designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java index 9947ce5a73..12b1d74b7c 100644 --- a/designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java +++ b/designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java @@ -27,17 +27,6 @@ public class DesignerPushUpdateManager { private DesignerUpdateInfo updateInfo; - static { - if (DesignerPushUpdateConfigManager.getInstance().isAutoPushUpdateEnabled()) { - DesignerContext.getDesignerFrame().addDesignerOpenedListener(new DesignerOpenedListener() { - @Override - public void designerOpened() { - getInstance().checkAndPop(); - } - }); - } - } - private DesignerPushUpdateManager() { } @@ -48,6 +37,17 @@ public class DesignerPushUpdateManager { return singleton; } + public void preparePushUpdate() { + if (DesignerPushUpdateConfigManager.getInstance().isAutoPushUpdateEnabled()) { + DesignerContext.getDesignerFrame().addDesignerOpenedListener(new DesignerOpenedListener() { + @Override + public void designerOpened() { + getInstance().checkAndPop(); + } + }); + } + } + private void initUpdateInfo(String currentVersion, String latestVersion) { String lastIgnoredVersion = DesignerPushUpdateConfigManager.getInstance().getLastIgnoredVersion(); String updatePushInfo = CloudCenter.getInstance().acquireUrlByKind("update.push"); diff --git a/designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java b/designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java index 1727906fb0..796b983f84 100644 --- a/designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java +++ b/designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java @@ -60,6 +60,7 @@ import com.fr.design.parameter.FormParameterReader; import com.fr.design.parameter.ParameterPropertyPane; import com.fr.design.parameter.WorkBookParameterReader; import com.fr.design.update.actions.RecoverForDesigner; +import com.fr.design.update.push.DesignerPushUpdateManager; import com.fr.design.widget.ui.btn.FormSubmitButtonDetailPane; import com.fr.form.stable.ElementCaseThumbnailProcessor; import com.fr.general.xml.GeneralXMLTools; @@ -102,6 +103,7 @@ import com.fr.stable.script.ValueConverter; import com.fr.stable.xml.ObjectTokenizer; import com.fr.stable.xml.ObjectXMLWriterFinder; import com.fr.start.BBSGuestPaneProvider; +import com.fr.task.Once; import com.fr.xml.ReportXMLUtils; import java.awt.*; @@ -119,6 +121,13 @@ public class DesignerActivator extends Activator { private LogHandler logHandler = null; + private final Once pushUpdateTask = new Once(new Runnable() { + @Override + public void run() { + DesignerPushUpdateManager.getInstance().preparePushUpdate(); + } + }); + @Override public void start() { List markers = findMutable(InterMutableKey.Path); @@ -139,6 +148,7 @@ public class DesignerActivator extends Activator { storePassport(); AlphaFineHelper.switchConfig4Locale(); RecoverManager.register(new RecoverForDesigner()); + pushUpdateTask.run(); } @Override