Browse Source

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

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

10
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,11 +35,16 @@ class DesignerPushUpdateDialog extends UIDialog {
initComponents(); initComponents();
} }
static void createAndShow(Frame parent, DesignerUpdateInfo updateInfo) { static void createAndShow(final Frame parent, final DesignerUpdateInfo updateInfo) {
SwingUtilities.invokeLater(new Runnable() {
public void run() {
DesignerPushUpdateDialog dialog = new DesignerPushUpdateDialog(parent); DesignerPushUpdateDialog dialog = new DesignerPushUpdateDialog(parent);
dialog.populate(updateInfo); dialog.populate(updateInfo);
dialog.showDialog(); dialog.showDialog();
} }
});
}
private void initComponents() { private void initComponents() {
JPanel contentPane = (JPanel) getContentPane(); JPanel contentPane = (JPanel) getContentPane();
@ -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