Changeset 7312 in josm for trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddWMSLayerPanel.java
- Timestamp:
- 2014-07-15T16:48:46+02:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddWMSLayerPanel.java
r7015 r7312 25 25 import org.openstreetmap.josm.data.imagery.ImageryInfo; 26 26 import org.openstreetmap.josm.gui.bbox.SlippyMapBBoxChooser; 27 import org.openstreetmap.josm.gui.util.GuiHelper; 27 28 import org.openstreetmap.josm.gui.widgets.JosmTextArea; 28 29 import org.openstreetmap.josm.io.imagery.WMSImagery; … … 86 87 tr("WMS Error"), JOptionPane.ERROR_MESSAGE); 87 88 } catch (WMSImagery.WMSGetCapabilitiesException ex) { 88 JOptionPane.showMessageDialog(getParent(), tr("Could not parse WMS layer list."), 89 tr("WMS Error"), JOptionPane.ERROR_MESSAGE); 90 Main.error("Could not parse WMS layer list. Incoming data:\n"+ex.getIncomingData()); 89 String incomingData = ex.getIncomingData().trim(); 90 String title = tr("WMS Error"); 91 String message = tr("Could not parse WMS layer list."); 92 Main.error("Could not parse WMS layer list. Incoming data:\n"+incomingData); 93 if (incomingData != null 94 && (incomingData.startsWith("<html>") || incomingData.startsWith("<HTML>")) 95 && (incomingData.endsWith("</html>") || incomingData.endsWith("</HTML>"))) { 96 GuiHelper.notifyUserHtmlError(AddWMSLayerPanel.this, title, message, incomingData); 97 } else { 98 JOptionPane.showMessageDialog(getParent(), message, title, JOptionPane.ERROR_MESSAGE); 99 } 91 100 } 92 101 }
Note:
See TracChangeset
for help on using the changeset viewer.
