Index: trunk/src/org/openstreetmap/josm/actions/JosmAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/JosmAction.java	(revision 8323)
+++ trunk/src/org/openstreetmap/josm/actions/JosmAction.java	(revision 8324)
@@ -8,5 +8,4 @@
 
 import javax.swing.AbstractAction;
-import javax.swing.Icon;
 
 import org.openstreetmap.josm.Main;
@@ -72,40 +71,4 @@
      * @param toolbarId identifier for the toolbar preferences. The iconName is used, if this parameter is null
      * @param installAdapters false, if you don't want to install layer changed and selection changed adapters
-     * @deprecated do not pass Icon, pass ImageProvider instead
-     */
-    @Deprecated
-    public JosmAction(String name, Icon icon, String tooltip, Shortcut shortcut, boolean registerInToolbar, String toolbarId, boolean installAdapters) {
-        super(name, icon);
-        setHelpId();
-        sc = shortcut;
-        if (sc != null) {
-            Main.registerActionShortcut(this, sc);
-        }
-        setTooltip(tooltip);
-        if (getValue("toolbar") == null) {
-            putValue("toolbar", toolbarId);
-        }
-        if (registerInToolbar && Main.toolbar != null) {
-            Main.toolbar.register(this);
-        }
-        if (installAdapters) {
-            installAdapters();
-        }
-    }
-
-    /**
-     * Constructs a {@code JosmAction}.
-     *
-     * @param name the action's text as displayed on the menu (if it is added to a menu)
-     * @param icon the icon to use
-     * @param tooltip  a longer description of the action that will be displayed in the tooltip. Please note
-     *           that html is not supported for menu actions on some platforms.
-     * @param shortcut a ready-created shortcut object or null if you don't want a shortcut. But you always
-     *            do want a shortcut, remember you can always register it with group=none, so you
-     *            won't be assigned a shortcut unless the user configures one. If you pass null here,
-     *            the user CANNOT configure a shortcut for your action.
-     * @param registerInToolbar register this action for the toolbar preferences?
-     * @param toolbarId identifier for the toolbar preferences. The iconName is used, if this parameter is null
-     * @param installAdapters false, if you don't want to install layer changed and selection changed adapters
      * TODO: do not pass Icon, pass ImageProvider instead
      */
Index: trunk/src/org/openstreetmap/josm/data/Preferences.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/Preferences.java	(revision 8323)
+++ trunk/src/org/openstreetmap/josm/data/Preferences.java	(revision 8324)
@@ -535,18 +535,4 @@
 
     /**
-     * Returns the location of the user defined preferences directory
-     * @return The location of the user defined preferences directory
-     * @deprecated use #getPreferencesDirectory() to access preferences directory
-     * or #getUserDataDirectory to access user data directory
-     */
-    @Deprecated
-    public String getPreferencesDir() {
-        final String path = getPreferencesDirectory().getPath();
-        if (path.endsWith(File.separator))
-            return path;
-        return path + File.separator;
-    }
-
-    /**
      * Returns the user defined preferences directory, containing the preferences.xml file
      * @return The user defined preferences directory, containing the preferences.xml file
@@ -1695,5 +1681,5 @@
                                  val += "&zip=1";
                                  modified = true;
-                                 
+
                              }
                              newmap.put(mkey, val);
Index: trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java	(revision 8323)
+++ trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ExpressionFactory.java	(revision 8324)
@@ -205,16 +205,4 @@
 
         /**
-         * Returns the first non-null object. The name originates from the {@code COALESCE} SQL function.
-         * @param args arguments
-         * @return the first non-null object
-         * @deprecated Deprecated in favour of {@link #any(Object...)} from the MapCSS standard.
-         */
-        @NullableArguments
-        @Deprecated
-        public static Object coalesce(Object... args) {
-            return any(args);
-        }
-
-        /**
          * Returns the first non-null object.
          * The name originates from <a href="http://wiki.openstreetmap.org/wiki/MapCSS/0.2/eval">MapCSS standard</a>.
Index: trunk/src/org/openstreetmap/josm/gui/preferences/SourceEditor.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/preferences/SourceEditor.java	(revision 8323)
+++ trunk/src/org/openstreetmap/josm/gui/preferences/SourceEditor.java	(revision 8324)
@@ -10,5 +10,4 @@
 import java.awt.GridBagConstraints;
 import java.awt.GridBagLayout;
-import java.awt.Image;
 import java.awt.Insets;
 import java.awt.Rectangle;
@@ -50,5 +49,4 @@
 import javax.swing.DefaultListSelectionModel;
 import javax.swing.Icon;
-import javax.swing.ImageIcon;
 import javax.swing.JButton;
 import javax.swing.JCheckBox;
@@ -96,5 +94,7 @@
 import org.openstreetmap.josm.io.OsmTransferException;
 import org.openstreetmap.josm.tools.GBC;
+import org.openstreetmap.josm.tools.ImageOverlay;
 import org.openstreetmap.josm.tools.ImageProvider;
+import org.openstreetmap.josm.tools.ImageProvider.ImageSizes;
 import org.openstreetmap.josm.tools.LanguageInfo;
 import org.openstreetmap.josm.tools.Utils;
@@ -1002,8 +1002,6 @@
                     dlg.setButtonIcons(new Icon[] {
                         ImageProvider.get("cancel"),
-                        ImageProvider.overlay(
-                            ImageProvider.get("ok"),
-                            new ImageIcon(ImageProvider.get("warning-small").getImage().getScaledInstance(12 , 12, Image.SCALE_SMOOTH)),
-                            ImageProvider.OverlayPosition.SOUTHEAST)
+                        new ImageProvider("ok").setMaxSize(ImageSizes.LARGEICON).addOverlay(
+                                new ImageOverlay(new ImageProvider("warning-small"), 0.5, 0.5, 1.0, 1.0)).get()
                     });
                     dlg.setToolTipTexts(new String[] {
Index: trunk/src/org/openstreetmap/josm/tools/ImageProvider.java
===================================================================
--- trunk/src/org/openstreetmap/josm/tools/ImageProvider.java	(revision 8323)
+++ trunk/src/org/openstreetmap/josm/tools/ImageProvider.java	(revision 8324)
@@ -52,5 +52,4 @@
 import javax.imageio.metadata.IIOMetadata;
 import javax.imageio.stream.ImageInputStream;
-import javax.swing.Icon;
 import javax.swing.ImageIcon;
 import javax.xml.bind.DatatypeConverter;
@@ -1144,51 +1143,4 @@
         return Toolkit.getDefaultToolkit().createCustomCursor(img.getImage(),
                 "crosshair".equals(name) ? new Point(10, 10) : new Point(3, 2), "Cursor");
-    }
-
-    /**
-     * Decorate one icon with an overlay icon.
-     *
-     * @param ground the base image
-     * @param overlay the overlay image (can be smaller than the base image)
-     * @param pos position of the overlay image inside the base image (positioned
-     * in one of the corners)
-     * @return an icon that represent the overlay of the two given icons. The second icon is layed
-     * on the first relative to the given position.
-     * FIXME: This function does not fit into the ImageProvider concept as public function!
-     * Overlay should be handled like all the other functions only settings arguments and
-     * overlay must be transparent in the background.
-     * Also scaling is not cared about with current implementation.
-     * @deprecated this method will be refactored
-     */
-    @Deprecated
-    public static ImageIcon overlay(Icon ground, Icon overlay, OverlayPosition pos) {
-        int w = ground.getIconWidth();
-        int h = ground.getIconHeight();
-        int wo = overlay.getIconWidth();
-        int ho = overlay.getIconHeight();
-        BufferedImage img = new BufferedImage(w, h, BufferedImage.TYPE_INT_ARGB);
-        Graphics g = img.createGraphics();
-        ground.paintIcon(null, g, 0, 0);
-        int x = 0, y = 0;
-        switch (pos) {
-        case NORTHWEST:
-            x = 0;
-            y = 0;
-            break;
-        case NORTHEAST:
-            x = w - wo;
-            y = 0;
-            break;
-        case SOUTHWEST:
-            x = 0;
-            y = h - ho;
-            break;
-        case SOUTHEAST:
-            x = w - wo;
-            y = h - ho;
-            break;
-        }
-        overlay.paintIcon(null, g, x, y);
-        return new ImageIcon(img);
     }
 
