- Timestamp:
- 2016-04-08T22:13:47+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/HelpAwareOptionPane.java
r10035 r10122 27 27 import javax.swing.event.ChangeListener; 28 28 29 import org.openstreetmap.josm.Main; 29 30 import org.openstreetmap.josm.gui.help.HelpBrowser; 30 31 import org.openstreetmap.josm.gui.help.HelpUtil; … … 229 230 } 230 231 231 if (msg instanceof String) {232 msg = new JMultilineLabel((String) msg, true);233 }234 235 232 final JOptionPane pane = new JOptionPane( 236 msg ,233 msg instanceof String ? new JMultilineLabel((String) msg, true) : msg, 237 234 messageType, 238 235 JOptionPane.DEFAULT_OPTION, … … 241 238 defaultButton 242 239 ); 240 241 // Log message. Useful for bug reports and unit tests 242 switch (messageType) { 243 case JOptionPane.ERROR_MESSAGE: 244 Main.error(title + " - " + msg); 245 break; 246 case JOptionPane.WARNING_MESSAGE: 247 Main.warn(title + " - " + msg); 248 break; 249 default: 250 Main.info(title + " - " + msg); 251 } 243 252 244 253 if (!GraphicsEnvironment.isHeadless()) {
Note:
See TracChangeset
for help on using the changeset viewer.