Changeset 21169 in osm
- Timestamp:
- 2010-05-07T22:37:50+02:00 (15 years ago)
- Location:
- applications/editors/josm/plugins/terracer
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/terracer/build.xml
r21166 r21169 32 32 33 33 34 <property name="commit.message" value=" Remember the interpolation setting between restarts" />34 <property name="commit.message" value="Fix the message text (and remove the now redundant message popup)" /> 35 35 <property name="plugin.main.version" value="3210" /> 36 36 -
applications/editors/josm/plugins/terracer/src/terracer/HouseNumberInputDialog.java
r21166 r21169 17 17 import java.awt.Frame; 18 18 import java.awt.GridBagLayout; 19 import java.awt.GridBagConstraints; 19 20 import java.awt.GridLayout; 20 21 import java.awt.event.ActionEvent; … … 105 106 setupDialog(); 106 107 setVisible(true); 108 lo.requestFocus(); 107 109 } 108 110 … … 126 128 private Container getJContentPane() { 127 129 if (jContentPane == null) { 128 129 messageLabel = new JTextArea(); 130 jContentPane = this.getContentPane(); 131 jContentPane.setLayout(new BoxLayout(jContentPane, BoxLayout.Y_AXIS)); 132 jContentPane.add(getInputPanel(), jContentPane); 133 } 134 return jContentPane; 135 } 136 137 /** 138 * This method initializes inputPanel 139 * 140 * @return javax.swing.JPanel 141 */ 142 private JPanel getInputPanel() { 143 if (inputPanel == null) { 144 145 GridBagConstraints c = new GridBagConstraints(); 146 147 messageLabel = new JTextArea(); 130 148 messageLabel.setText(DEFAULT_MESSAGE); 131 149 messageLabel.setAutoscrolls(true); … … 135 153 messageLabel.setBackground(new Color(238, 238, 238)); 136 154 messageLabel.setEditable(false); 155 messageLabel.setFocusable(false); // Needed so that lowest number can have focus immediately 137 156 138 jContentPane = this.getContentPane();139 jContentPane.setLayout(new BoxLayout(jContentPane, BoxLayout.Y_AXIS));140 jContentPane.add(messageLabel, jContentPane);141 jContentPane.add(getInputPanel(), jContentPane);142 }143 return jContentPane;144 }145 146 /**147 * This method initializes inputPanel148 *149 * @return javax.swing.JPanel150 */151 private JPanel getInputPanel() {152 if (inputPanel == null) {153 157 interpolationLabel = new JLabel(); 154 158 interpolationLabel.setText(tr("Interpolation")); … … 170 174 inputPanel = new JPanel(); 171 175 inputPanel.setLayout(new GridBagLayout()); 176 c.fill = GridBagConstraints.HORIZONTAL; 177 c.gridwidth = GridBagConstraints.REMAINDER; 178 inputPanel.add(messageLabel, c); 179 172 180 inputPanel.add(loLabel, GBC.std().insets(3,3,0,0)); 173 181 inputPanel.add(getLo(), GBC.eol().fill(GBC.HORIZONTAL).insets(5,3,0,0)); … … 207 215 lo = new JTextField(); 208 216 lo.setText(""); 209 lo.requestFocus();210 217 } 211 218 return lo; -
applications/editors/josm/plugins/terracer/src/terracer/HouseNumberInputHandler.java
r21166 r21169 138 138 dialog.messageLabel.setForeground(Color.red); 139 139 dialog.messageLabel.setText(message.toString()); 140 JOptionPane.showMessageDialog(null, message.toString(), tr("Error"), JOptionPane.ERROR_MESSAGE);140 //JOptionPane.showMessageDialog(null, message.toString(), tr("Error"), JOptionPane.ERROR_MESSAGE); 141 141 142 142 return false;
Note:
See TracChangeset
for help on using the changeset viewer.