Index: trunk/src/org/openstreetmap/josm/actions/GpxExportAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/GpxExportAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/GpxExportAction.java	(revision 1857)
@@ -231,5 +231,10 @@
         } catch (IOException x) {
             x.printStackTrace();
-            JOptionPane.showMessageDialog(Main.parent, tr("Error while exporting {0}:\n{1}", fn,x.getMessage()), tr("Error"), JOptionPane.ERROR_MESSAGE);
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("Error while exporting {0}:\n{1}", fn,x.getMessage()),
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE
+            );
         }
     }
@@ -285,5 +290,11 @@
                 l.setVisibleRowCount(4);
                 l.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
-                int answer = JOptionPane.showConfirmDialog(Main.parent, new JScrollPane(l),tr("Choose a predefined license"), JOptionPane.OK_CANCEL_OPTION);
+                int answer = OptionPaneUtil.showConfirmationDialog(
+                        Main.parent,
+                        new JScrollPane(l),
+                        tr("Choose a predefined license"),
+                        JOptionPane.OK_CANCEL_OPTION,
+                        JOptionPane.QUESTION_MESSAGE
+                );
                 if (answer != JOptionPane.OK_OPTION || l.getSelectedIndex() == -1)
                     return;
Index: trunk/src/org/openstreetmap/josm/actions/MergeNodesAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/MergeNodesAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/MergeNodesAction.java	(revision 1857)
@@ -37,4 +37,5 @@
 import org.openstreetmap.josm.data.osm.visitor.CollectBackReferencesVisitor;
 import org.openstreetmap.josm.gui.ExtendedDialog;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.tools.GBC;
 import org.openstreetmap.josm.tools.Pair;
@@ -72,5 +73,5 @@
 
         if (selectedNodes.size() < 2) {
-            JOptionPane.showMessageDialog(
+            OptionPaneUtil.showMessageDialog(
                     Main.parent,
                     tr("Please select at least two nodes to merge."),
@@ -249,7 +250,11 @@
                 w.visit(backRefs);
                 if (!backRefs.data.isEmpty()) {
-                    JOptionPane.showMessageDialog(Main.parent,
+                    OptionPaneUtil.showMessageDialog(
+                            Main.parent,
                             tr("Cannot merge nodes: " +
-                            "Would have to delete a way that is still used."));
+                            "Would have to delete a way that is still used."),
+                            tr("Warning"),
+                            JOptionPane.WARNING_MESSAGE
+                    );
                     return null;
                 }
Index: trunk/src/org/openstreetmap/josm/actions/MirrorAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/MirrorAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/MirrorAction.java	(revision 1857)
@@ -19,4 +19,5 @@
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
 import org.openstreetmap.josm.data.osm.Way;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.tools.Shortcut;
 
@@ -49,5 +50,5 @@
 
         if (nodes.size() == 0) {
-            JOptionPane.showMessageDialog(
+            OptionPaneUtil.showMessageDialog(
                     Main.parent,
                     tr("Please select at least one node or way."),
Index: trunk/src/org/openstreetmap/josm/actions/OrthogonalizeAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/OrthogonalizeAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/OrthogonalizeAction.java	(revision 1857)
@@ -106,5 +106,10 @@
                 }
                 if(delta < Math.PI/4) {
-                    JOptionPane.showMessageDialog(Main.parent, tr("Please select ways with almost right angles to orthogonalize."));
+                    OptionPaneUtil.showMessageDialog(
+                            Main.parent,
+                            tr("Please select ways with almost right angles to orthogonalize."),
+                            tr("Information"),
+                            JOptionPane.INFORMATION_MESSAGE
+                    );
                     return;
                 }
Index: trunk/src/org/openstreetmap/josm/actions/SaveActionBase.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/SaveActionBase.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/SaveActionBase.java	(revision 1857)
@@ -87,9 +87,14 @@
     public boolean checkSaveConditions(Layer layer) {
         if (layer == null) {
-            JOptionPane.showMessageDialog(Main.parent, tr("Internal Error: cannot check conditions for no layer. Please report this as a bug."));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("Internal Error: cannot check conditions for no layer. Please report this as a bug."),
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE
+            );
             return false;
         }
         if (Main.map == null) {
-            JOptionPane.showMessageDialog(
+            OptionPaneUtil.showMessageDialog(
                     Main.parent,
                     tr("No document open so nothing to save."),
@@ -271,5 +276,10 @@
         } catch (IOException e) {
             e.printStackTrace();
-            JOptionPane.showMessageDialog(Main.parent, tr("An error occurred while saving.")+"\n"+e.getMessage());
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("An error occurred while saving. Error is: {0}", e.getMessage()),
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE
+            );
         }
         try {
Index: trunk/src/org/openstreetmap/josm/actions/SplitWayAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/SplitWayAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/SplitWayAction.java	(revision 1857)
@@ -31,4 +31,5 @@
 import org.openstreetmap.josm.data.osm.visitor.AbstractVisitor;
 import org.openstreetmap.josm.data.osm.visitor.Visitor;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.gui.PrimitiveNameFormatter;
 import org.openstreetmap.josm.tools.Shortcut;
@@ -65,5 +66,10 @@
 
         if (!checkSelection(selection)) {
-            JOptionPane.showMessageDialog(Main.parent, tr("The current selection cannot be used for splitting."));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("The current selection cannot be used for splitting."),
+                    tr("Warning"),
+                    JOptionPane.WARNING_MESSAGE
+            );
             return;
         }
@@ -117,8 +123,10 @@
             }
             if (wayOccurenceCounter.isEmpty()) {
-                JOptionPane.showMessageDialog(Main.parent,
+                OptionPaneUtil.showMessageDialog(Main.parent,
                         trn("The selected node is not in the middle of any way.",
                                 "The selected nodes are not in the middle of any way.",
-                                selectedNodes.size()));
+                                selectedNodes.size()),
+                                tr("Warning"),
+                                JOptionPane.WARNING_MESSAGE);
                 return;
             }
@@ -127,8 +135,10 @@
                 if (entry.getValue().equals(selectedNodes.size())) {
                     if (selectedWay != null) {
-                        JOptionPane.showMessageDialog(Main.parent,
+                        OptionPaneUtil.showMessageDialog(Main.parent,
                                 trn("There is more than one way using the node you selected. Please select the way also.",
                                         "There is more than one way using the nodes you selected. Please select the way also.",
-                                        selectedNodes.size()));
+                                        selectedNodes.size()),
+                                        tr("Warning"),
+                                        JOptionPane.WARNING_MESSAGE);
                         return;
                     }
@@ -138,6 +148,8 @@
 
             if (selectedWay == null) {
-                JOptionPane.showMessageDialog(Main.parent,
-                        tr("The selected nodes do not share the same way."));
+                OptionPaneUtil.showMessageDialog(Main.parent,
+                        tr("The selected nodes do not share the same way."),
+                        tr("Warning"),
+                        JOptionPane.WARNING_MESSAGE);
                 return;
             }
@@ -151,8 +163,10 @@
             }
             if (!nds.isEmpty()) {
-                JOptionPane.showMessageDialog(Main.parent,
+                OptionPaneUtil.showMessageDialog(Main.parent,
                         trn("The selected way does not contain the selected node.",
                                 "The selected way does not contain all the selected nodes.",
-                                selectedNodes.size()));
+                                selectedNodes.size()),
+                                tr("Warning"),
+                                JOptionPane.WARNING_MESSAGE);
                 return;
             }
@@ -219,5 +233,9 @@
                 && !nodeSet.contains(wayChunks.get(0).get(0))) {
             if (wayChunks.size() == 2) {
-                JOptionPane.showMessageDialog(Main.parent, tr("You must select two or more nodes to split a circular way."));
+                OptionPaneUtil.showMessageDialog(
+                        Main.parent,
+                        tr("You must select two or more nodes to split a circular way."),
+                        tr("Warning"),
+                        JOptionPane.WARNING_MESSAGE);
                 return;
             }
@@ -230,7 +248,15 @@
         if (wayChunks.size() < 2) {
             if(wayChunks.get(0).get(0) == wayChunks.get(0).get(wayChunks.get(0).size()-1)) {
-                JOptionPane.showMessageDialog(Main.parent, tr("You must select two or more nodes to split a circular way."));
+                OptionPaneUtil.showMessageDialog(
+                        Main.parent,
+                        tr("You must select two or more nodes to split a circular way."),
+                        tr("Warning"),
+                        JOptionPane.WARNING_MESSAGE);
             } else {
-                JOptionPane.showMessageDialog(Main.parent, tr("The way cannot be split at the selected nodes. (Hint: Select nodes in the middle of the way.)"));
+                OptionPaneUtil.showMessageDialog(
+                        Main.parent,
+                        tr("The way cannot be split at the selected nodes. (Hint: Select nodes in the middle of the way.)"),
+                        tr("Warning"),
+                        JOptionPane.WARNING_MESSAGE);
             }
             return;
@@ -321,7 +347,15 @@
         }
         if(warnmerole) {
-            JOptionPane.showMessageDialog(Main.parent, tr("A role based relation membership was copied to all new ways.\nYou should verify this and correct it when necessary."));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("<html>A role based relation membership was copied to all new ways.<br>You should verify this and correct it when necessary.</html>"),
+                    tr("Warning"),
+                    JOptionPane.WARNING_MESSAGE);
         } else if(warnme) {
-            JOptionPane.showMessageDialog(Main.parent, tr("A relation membership was copied to all new ways.\nYou should verify this and correct it when necessary."));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("<html>A relation membership was copied to all new ways.<br>You should verify this and correct it when necessary.</html>"),
+                    tr("Warning"),
+                    JOptionPane.WARNING_MESSAGE);
         }
 
Index: trunk/src/org/openstreetmap/josm/actions/UnGlueAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/UnGlueAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/UnGlueAction.java	(revision 1857)
@@ -27,4 +27,5 @@
 import org.openstreetmap.josm.data.osm.Way;
 import org.openstreetmap.josm.gui.MapView;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.tools.Shortcut;
 
@@ -131,5 +132,9 @@
 
         if(errMsg != null) {
-            JOptionPane.showMessageDialog(Main.parent, errMsg);
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    errMsg,
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE);
         }
 
Index: trunk/src/org/openstreetmap/josm/actions/UpdateDataAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/UpdateDataAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/UpdateDataAction.java	(revision 1857)
@@ -15,4 +15,5 @@
 import org.openstreetmap.josm.actions.downloadtasks.DownloadOsmTaskList;
 import org.openstreetmap.josm.data.osm.DataSource;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.gui.layer.Layer;
 import org.openstreetmap.josm.gui.layer.Layer.LayerChangeListener;
@@ -73,5 +74,5 @@
 
         if(bboxCount == 0) {
-            JOptionPane.showMessageDialog(
+            OptionPaneUtil.showMessageDialog(
                     Main.parent,
                     tr("No data to update found. Have you already opened or downloaded a data layer?"),
Index: trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java	(revision 1857)
@@ -17,4 +17,5 @@
 import org.openstreetmap.josm.data.osm.DataSet;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.gui.PleaseWaitRunnable;
 import org.openstreetmap.josm.gui.layer.Layer;
@@ -205,5 +206,5 @@
         Collection<OsmPrimitive> selection = getCurrentDataSet().getSelected();
         if (selection.size() == 0) {
-            JOptionPane.showMessageDialog(
+            OptionPaneUtil.showMessageDialog(
                     Main.parent,
                     tr("There are no selected primitives to update."),
Index: trunk/src/org/openstreetmap/josm/actions/UploadAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/UploadAction.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/UploadAction.java	(revision 1857)
@@ -26,4 +26,5 @@
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
 import org.openstreetmap.josm.gui.ExtendedDialog;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.gui.OsmPrimitivRenderer;
 import org.openstreetmap.josm.gui.PleaseWaitRunnable;
@@ -174,5 +175,10 @@
         ConflictCollection conflicts = Main.map.mapView.getEditLayer().getConflicts();
         if (conflicts !=null && !conflicts.isEmpty()) {
-            JOptionPane.showMessageDialog(Main.parent,tr("There are unresolved conflicts. You have to resolve these first."));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("There are unresolved conflicts. You have to resolve these first."),
+                    tr("Warning"),
+                    JOptionPane.WARNING_MESSAGE
+            );
             Main.map.conflictDialog.action.button.setSelected(true);
             Main.map.conflictDialog.action.actionPerformed(null);
Index: trunk/src/org/openstreetmap/josm/actions/search/SelectionWebsiteLoader.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/search/SelectionWebsiteLoader.java	(revision 1856)
+++ trunk/src/org/openstreetmap/josm/actions/search/SelectionWebsiteLoader.java	(revision 1857)
@@ -20,4 +20,5 @@
 import org.openstreetmap.josm.Main;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
+import org.openstreetmap.josm.gui.OptionPaneUtil;
 import org.openstreetmap.josm.gui.PleaseWaitRunnable;
 import org.openstreetmap.josm.io.OsmIdReader;
@@ -59,20 +60,31 @@
         } catch (IOException e) {
             e.printStackTrace();
-            JOptionPane.showMessageDialog(Main.parent, tr("Could not read from URL: \"{0}\"",url));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("Could not read from URL: \"{0}\"",url),
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE
+            );
         } catch (SAXException e) {
             e.printStackTrace();
-            JOptionPane.showMessageDialog(Main.parent,tr("Parsing error in URL: \"{0}\"",url));
+            OptionPaneUtil.showMessageDialog(
+                    Main.parent,
+                    tr("Parsing error in URL: \"{0}\"",url),
+                    tr("Error"),
+                    JOptionPane.ERROR_MESSAGE
+            );
         } catch(OsmTransferException e) {
             e.printStackTrace();
             if (e.getCause() != null) {
                 if (e.getCause() instanceof IOException ) {
-                    JOptionPane.showMessageDialog(Main.parent, tr("Could not read from URL: \"{0}\"",url),
+                    OptionPaneUtil.showMessageDialog(
+                            Main.parent, tr("Could not read from URL: \"{0}\"",url),
                             tr("Error"), JOptionPane.ERROR_MESSAGE);
                 } else if (e.getCause() instanceof SAXException) {
-                    JOptionPane.showMessageDialog(Main.parent,tr("Parsing error in URL: \"{0}\"",url),
+                    OptionPaneUtil.showMessageDialog(Main.parent,tr("Parsing error in URL: \"{0}\"",url),
                             tr("Error"), JOptionPane.ERROR_MESSAGE);
                 }
             } else {
-                JOptionPane.showMessageDialog(Main.parent,tr("Error while communicating with server.",url),
+                OptionPaneUtil.showMessageDialog(Main.parent,tr("Error while communicating with server.",url),
                         tr("Error"), JOptionPane.ERROR_MESSAGE);
             }
