Browse Source

Fixes issue 3516: SwingRestartDialog packs down to an unusable size

Change-Id: I687f8d77f54a84dc220fc01099494957ae5979cf
Reviewed-on: http://gerrit.dmdirc.com/501
Automatic-Compile: Shane Mc Cormack <shane@dmdirc.com>
Reviewed-by: Shane Mc Cormack <shane@dmdirc.com>
tags/0.6.3
Gregory Holmes 14 years ago
parent
commit
a5071072df

+ 10
- 2
src/com/dmdirc/addons/ui_swing/dialogs/updater/SwingRestartDialog.java View File

@@ -106,13 +106,21 @@ public class SwingRestartDialog extends StandardDialog implements ActionListener
106 106
     
107 107
     /** Layout Components. */
108 108
     public void layoutComponents() {
109
-        setLayout(new MigLayout("fill, wrap 2"));
109
+        setLayout(new MigLayout("fill, wrap 2, wmax " +
110
+                mainFrame.getSize().getWidth() + ", pack"));
110 111
         
111
-        add(info, "grow, pushy, span 2");
112
+        add(info, "grow, pushx, span 2");
112 113
         add(getLeftButton(), "split, right");
113 114
         add(getRightButton(), "right");
114 115
     }
115 116
 
117
+    /** {@inheritDoc} */
118
+    @Override
119
+    public void validate() {
120
+        super.validate();
121
+        setLocationRelativeTo(mainFrame);
122
+    }
123
+
116 124
     /** 
117 125
      * {@inheritDoc}
118 126
      * 

Loading…
Cancel
Save