Index: /trunk/src/org/openstreetmap/josm/actions/AddImageryLayerAction.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/actions/AddImageryLayerAction.java	(revision 10713)
+++ /trunk/src/org/openstreetmap/josm/actions/AddImageryLayerAction.java	(revision 10714)
@@ -32,5 +32,4 @@
 import org.openstreetmap.josm.tools.GBC;
 import org.openstreetmap.josm.tools.ImageProvider;
-import org.openstreetmap.josm.tools.ImageResource;
 
 /**
@@ -56,5 +55,5 @@
         String icon = info.getIcon();
         if (icon != null) {
-            new ImageProvider(icon).setOptional(true).getInBackground((ImageResource result) -> {
+            new ImageProvider(icon).setOptional(true).getResourceAsync().thenAccept(result -> {
                 if (result != null) {
                     GuiHelper.runInEDT(() -> result.attachImageIcon(this));
Index: /trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java	(revision 10713)
+++ /trunk/src/org/openstreetmap/josm/gui/mappaint/styleelement/MapImage.java	(revision 10714)
@@ -19,5 +19,4 @@
 import org.openstreetmap.josm.gui.util.GuiHelper;
 import org.openstreetmap.josm.tools.ImageProvider;
-import org.openstreetmap.josm.tools.ImageProvider.ImageCallback;
 import org.openstreetmap.josm.tools.Utils;
 
@@ -99,5 +98,5 @@
                 .setHeight(height)
                 .setOptional(true)
-                .getInBackground((ImageCallback) result -> {
+                .getAsync().thenAccept(result -> {
                     synchronized (this) {
                         if (result == null) {
Index: /trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPreset.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPreset.java	(revision 10713)
+++ /trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPreset.java	(revision 10714)
@@ -60,5 +60,4 @@
 import org.openstreetmap.josm.tools.GBC;
 import org.openstreetmap.josm.tools.ImageProvider;
-import org.openstreetmap.josm.tools.ImageProvider.ImageResourceCallback;
 import org.openstreetmap.josm.tools.Utils;
 import org.openstreetmap.josm.tools.template_engine.ParseError;
@@ -204,5 +203,5 @@
         imgProv.setArchive(arch);
         imgProv.setOptional(true);
-        imgProv.getInBackground((ImageResourceCallback) result -> {
+        imgProv.getResourceAsync().thenAccept(result -> {
             if (result != null) {
                 GuiHelper.runInEDT(() -> result.attachImageIcon(this));
Index: /trunk/src/org/openstreetmap/josm/tools/ImageProvider.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/tools/ImageProvider.java	(revision 10713)
+++ /trunk/src/org/openstreetmap/josm/tools/ImageProvider.java	(revision 10714)
@@ -40,4 +40,5 @@
 import java.util.Map;
 import java.util.TreeSet;
+import java.util.concurrent.CompletableFuture;
 import java.util.concurrent.ExecutorService;
 import java.util.concurrent.Executors;
@@ -308,31 +309,4 @@
 
     /**
-     * Callback interface for asynchronous image loading.
-     * @since 10600 (functional interface)
-     */
-    @FunctionalInterface
-    public interface ImageCallback {
-        /**
-         * Called when image loading has finished.
-         * @param result the loaded image icon
-         */
-        void finished(ImageIcon result);
-    }
-
-    /**
-     * Callback interface for asynchronous image loading (with delayed scaling possibility).
-     * @since 7693
-     * @since 10600 (functional interface)
-     */
-    @FunctionalInterface
-    public interface ImageResourceCallback {
-        /**
-         * Called when image loading has finished.
-         * @param result the loaded image resource
-         */
-        void finished(ImageResource result);
-    }
-
-    /**
      * Constructs a new {@code ImageProvider} from a filename in a given directory.
      * @param subdir subdirectory the image lies in
@@ -653,4 +627,16 @@
 
     /**
+     * Load the image in a background thread.
+     *
+     * This method returns immediately and runs the image request asynchronously.
+     *
+     * @return the future of the requested image
+     * @since 10714
+     */
+    public CompletableFuture<ImageIcon> getAsync() {
+        return CompletableFuture.supplyAsync(this::get, IMAGE_FETCHER);
+    }
+
+    /**
      * Execute the image request.
      *
@@ -687,34 +673,9 @@
      * This method returns immediately and runs the image request asynchronously.
      *
-     * @param callback a callback. It is called, when the image is ready.
-     * This can happen before the call to this method returns or it may be
-     * invoked some time (seconds) later. If no image is available, a null
-     * value is returned to callback (just like {@link #get}).
-     */
-    public void getInBackground(final ImageCallback callback) {
-        if (name.startsWith(HTTP_PROTOCOL) || name.startsWith(WIKI_PROTOCOL)) {
-            IMAGE_FETCHER.submit(() -> callback.finished(get()));
-        } else {
-            callback.finished(get());
-        }
-    }
-
-    /**
-     * Load the image in a background thread.
-     *
-     * This method returns immediately and runs the image request asynchronously.
-     *
-     * @param callback a callback. It is called, when the image is ready.
-     * This can happen before the call to this method returns or it may be
-     * invoked some time (seconds) later. If no image is available, a null
-     * value is returned to callback (just like {@link #get}).
-     * @since 7693
-     */
-    public void getInBackground(final ImageResourceCallback callback) {
-        if (name.startsWith(HTTP_PROTOCOL) || name.startsWith(WIKI_PROTOCOL)) {
-            IMAGE_FETCHER.submit(() -> callback.finished(getResource()));
-        } else {
-            callback.finished(getResource());
-        }
+     * @return the future of the requested image
+     * @since 10714
+     */
+     public CompletableFuture<ImageResource> getResourceAsync() {
+        return CompletableFuture.supplyAsync(this::getResource, IMAGE_FETCHER);
     }
 
