Changeset 16217 in josm for trunk/src/org
- Timestamp:
- 2020-03-29T10:10:42+02:00 (5 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/ExceptionDialogUtil.java
r15084 r16217 16 16 17 17 import org.openstreetmap.josm.data.osm.OsmPrimitive; 18 import org.openstreetmap.josm.gui.widgets.HtmlPanel;19 18 import org.openstreetmap.josm.io.ChangesetClosedException; 20 19 import org.openstreetmap.josm.io.IllegalDataException; … … 45 44 return HelpAwareOptionPane.showOptionDialog( 46 45 MainApplication.getMainFrame(), 47 new HtmlPanel(msg),46 msg, 48 47 title, 49 48 JOptionPane.ERROR_MESSAGE, … … 336 335 Object msg = null; 337 336 if (e.isHtml() && body != null && body.startsWith("<") && body.contains("<html>")) { 338 msg = new HtmlPanel(body);337 // use html string as is 339 338 } else { 340 339 msg = ExceptionUtil.explainGeneric(e); -
trunk/src/org/openstreetmap/josm/gui/HelpAwareOptionPane.java
r13842 r16217 28 28 import org.openstreetmap.josm.gui.util.GuiHelper; 29 29 import org.openstreetmap.josm.gui.util.WindowGeometry; 30 import org.openstreetmap.josm.gui.widgets. JMultilineLabel;30 import org.openstreetmap.josm.gui.widgets.HtmlPanel; 31 31 import org.openstreetmap.josm.tools.ImageProvider; 32 32 import org.openstreetmap.josm.tools.ImageProvider.ImageSizes; … … 258 258 } 259 259 } 260 260 final Object content; 261 if (msg instanceof String) { 262 String msgStr = (String) msg; 263 content = new HtmlPanel(msgStr.startsWith("<html>") ? msgStr : "<html>" + msgStr + "</html>"); 264 } else { 265 content = msg; 266 } 261 267 final JOptionPane pane = new JOptionPane( 262 msg instanceof String ? new JMultilineLabel((String) msg, true) : msg,268 content, 263 269 messageType, 264 270 JOptionPane.DEFAULT_OPTION,
Note:
See TracChangeset
for help on using the changeset viewer.