Browse Source

REPORT-14865 更新日志推送=>显示最新版本号

research/10.0
plough 6 years ago
parent
commit
da3514e4db
  1. 16
      designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateDialog.java

16
designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateDialog.java

@ -16,6 +16,7 @@ import com.fr.web.struct.category.StylePath;
import com.fr.web.struct.impl.FineUI; import com.fr.web.struct.impl.FineUI;
import javax.swing.JPanel; import javax.swing.JPanel;
import javax.swing.SwingUtilities;
import java.awt.BorderLayout; import java.awt.BorderLayout;
import java.awt.Dimension; import java.awt.Dimension;
import java.awt.Frame; import java.awt.Frame;
@ -34,10 +35,15 @@ class DesignerPushUpdateDialog extends UIDialog {
initComponents(); initComponents();
} }
static void createAndShow(Frame parent, DesignerUpdateInfo updateInfo) { static void createAndShow(final Frame parent, final DesignerUpdateInfo updateInfo) {
DesignerPushUpdateDialog dialog = new DesignerPushUpdateDialog(parent); SwingUtilities.invokeLater(new Runnable() {
dialog.populate(updateInfo); public void run() {
dialog.showDialog(); DesignerPushUpdateDialog dialog = new DesignerPushUpdateDialog(parent);
dialog.populate(updateInfo);
dialog.showDialog();
}
});
} }
private void initComponents() { private void initComponents() {
@ -72,7 +78,7 @@ class DesignerPushUpdateDialog extends UIDialog {
private Model createModel(DesignerUpdateInfo updateInfo) { private Model createModel(DesignerUpdateInfo updateInfo) {
Model model = new Model(); Model model = new Model();
model.setVersion(updateInfo.getPushVersion()); model.setVersion(updateInfo.getLatestVersion());
model.setContent(updateInfo.getPushContent()); model.setContent(updateInfo.getPushContent());
model.setMoreInfoUrl(updateInfo.getMoreInfoUrl()); model.setMoreInfoUrl(updateInfo.getMoreInfoUrl());
model.setBackgroundUrl(updateInfo.getBackgroundUrl()); model.setBackgroundUrl(updateInfo.getBackgroundUrl());

Loading…
Cancel
Save