import java.util.List;
import javax.swing.JButton;
+import javax.swing.JCheckBox;
import javax.swing.JDialog;
import javax.swing.JLabel;
import javax.swing.JPanel;
import net.miginfocom.swing.MigLayout;
import net.sf.openrocket.communication.UpdateInfo;
import net.sf.openrocket.gui.components.URLLabel;
+import net.sf.openrocket.util.Chars;
import net.sf.openrocket.util.ComparablePair;
import net.sf.openrocket.util.GUIUtil;
import net.sf.openrocket.util.Icons;
public class UpdateInfoDialog extends JDialog {
+
+ private final JCheckBox remind;
public UpdateInfoDialog(UpdateInfo info) {
super((Window)null, "OpenRocket update available", ModalityType.APPLICATION_MODAL);
if (count >= 4 && n != updates.get(i).getU())
break;
n = updates.get(i).getU();
- panel.add(new JLabel(" \u2022 " + updates.get(i).getV()), "wrap 0px");
+ panel.add(new JLabel(" " + Chars.BULLET + " " + updates.get(i).getV()),
+ "wrap 0px");
count++;
}
}
"gaptop para, alignx 50%, wrap unrel");
panel.add(new URLLabel(AboutDialog.OPENROCKET_URL), "alignx 50%, wrap para");
+ remind = new JCheckBox("Remind me later");
+ remind.setToolTipText("Show this update also the next time you start OpenRocket");
+ remind.setSelected(true);
+ panel.add(remind);
+
JButton button = new JButton("Close");
button.addActionListener(new ActionListener() {
@Override
UpdateInfoDialog.this.dispose();
}
});
- panel.add(button, "right");
+ panel.add(button, "right, gapright para");
this.add(panel);
GUIUtil.setDisposableDialogOptions(this, button);
}
+
+ public boolean isReminderSelected() {
+ return remind.isSelected();
+ }
+
}