Index: applications/editors/josm/plugins/waydownloader/build.xml
===================================================================
--- applications/editors/josm/plugins/waydownloader/build.xml	(revision 33538)
+++ applications/editors/josm/plugins/waydownloader/build.xml	(revision 33539)
@@ -5,5 +5,5 @@
     <property name="commit.message" value="Changed the constructor signature of the plugin main class"/>
     <!-- enter the *lowest* JOSM version this plugin is currently compatible with -->
-    <property name="plugin.main.version" value="10580"/>
+    <property name="plugin.main.version" value="12663"/>
 
     <property name="plugin.author" value="Harry Wood"/>
Index: applications/editors/josm/plugins/waydownloader/src/org/openstreetmap/josm/plugins/waydownloader/WayDownloaderPlugin.java
===================================================================
--- applications/editors/josm/plugins/waydownloader/src/org/openstreetmap/josm/plugins/waydownloader/WayDownloaderPlugin.java	(revision 33538)
+++ applications/editors/josm/plugins/waydownloader/src/org/openstreetmap/josm/plugins/waydownloader/WayDownloaderPlugin.java	(revision 33539)
@@ -23,8 +23,9 @@
 import org.openstreetmap.josm.data.coor.LatLon;
 import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.data.osm.DefaultNameFormatter;
 import org.openstreetmap.josm.data.osm.Node;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
 import org.openstreetmap.josm.data.osm.Way;
-import org.openstreetmap.josm.gui.DefaultNameFormatter;
+import org.openstreetmap.josm.gui.MainApplication;
 import org.openstreetmap.josm.gui.MainMenu;
 import org.openstreetmap.josm.gui.Notification;
@@ -33,4 +34,5 @@
 import org.openstreetmap.josm.plugins.Plugin;
 import org.openstreetmap.josm.plugins.PluginInformation;
+import org.openstreetmap.josm.tools.Logging;
 import org.openstreetmap.josm.tools.Shortcut;
 
@@ -49,5 +51,5 @@
         super(info);
         //add WayDownloadAction to tools menu
-        MainMenu.add(Main.main.menu.moreToolsMenu, new WayDownloadAction());
+        MainMenu.add(MainApplication.getMenu().moreToolsMenu, new WayDownloadAction());
     }
 
@@ -67,5 +69,5 @@
         public void actionPerformed(ActionEvent e) {
             selectedNode = null;
-            DataSet ds = Main.getLayerManager().getEditDataSet();
+            DataSet ds = MainApplication.getLayerManager().getEditDataSet();
             Collection<Node> selection = ds.getSelectedNodes();
             if (selection.isEmpty()) {
@@ -84,5 +86,5 @@
 
             selectedNode = (Node) selection.iterator().next();
-            Main.map.mapView.zoomTo(selectedNode.getEastNorth());
+            MainApplication.getMap().mapView.zoomTo(selectedNode.getEastNorth());
 
             //Before downloading. Figure a few things out.
@@ -116,21 +118,18 @@
             // schedule closing of the progress monitor after the download
             // job has finished
-            Main.worker.submit(
-                    new Runnable() {
-                        @Override
-                        public void run() {
-                            try {
-                                future.get();
-                            } catch(Exception e) {
-                                Main.error(e);
-                                return;
-                            }
-                            monitor.close();
-                        }
-                    }
+            MainApplication.worker.submit(
+                    () -> {
+					    try {
+					        future.get();
+					    } catch(Exception e1) {
+					        Logging.error(e1);
+					        return;
+					    }
+					    monitor.close();
+					}
             );
             //The download is scheduled to be executed.
             //Now schedule the run() method (below) to be executed once that's completed.
-            Main.worker.execute(this);
+            MainApplication.worker.execute(this);
         }
 
@@ -177,11 +176,11 @@
                         return;
                     Command cmd = MergeNodesAction.mergeNodes(
-                            Main.getLayerManager().getEditLayer(),
+                    		MainApplication.getLayerManager().getEditLayer(),
                             Collections.singletonList(dupeNode),
                             selectedNode
                     );
                     if (cmd != null) {
-                        Main.main.undoRedo.add(cmd);
-                        Main.getLayerManager().getEditLayer().data.setSelected(selectedNode);
+                    	MainApplication.undoRedo.add(cmd);
+                        MainApplication.getLayerManager().getEditLayer().data.setSelected(selectedNode);
                     }
                     connectedWays = findConnectedWays(selectedNode);
@@ -214,6 +213,6 @@
 
                 //Select the next node
-                Main.getLayerManager().getEditDataSet().setSelected(nextNode);
-                Main.map.mapView.zoomTo(nextNode.getEastNorth());
+                MainApplication.getLayerManager().getEditDataSet().setSelected(nextNode);
+                MainApplication.getMap().mapView.zoomTo(nextNode.getEastNorth());
             }
         }
@@ -237,5 +236,5 @@
      */
     private Node findDuplicateNode(Node referenceNode) {
-        DataSet ds = Main.getLayerManager().getEditDataSet();
+        DataSet ds = MainApplication.getLayerManager().getEditDataSet();
         List<Node> candidates = ds.searchNodes(new Bounds(referenceNode.getCoor(), 0.0003, 0.0005).toBBox());
         for (Node candidate: candidates) {
@@ -290,10 +289,10 @@
             if (isDownloaded(selectedNode)) return false;
         }
-        Main.getLayerManager().getEditDataSet().setSelected(selectedNode);
+        MainApplication.getLayerManager().getEditDataSet().setSelected(selectedNode);
         return true;
     }
 
     private boolean isDownloaded(Node node) {
-        for (DataSource datasource : Main.getLayerManager().getEditDataSet().getDataSources()) {
+        for (DataSource datasource : MainApplication.getLayerManager().getEditDataSet().getDataSources()) {
             Bounds bounds = datasource.bounds;
             if (bounds != null && bounds.contains(node.getCoor())) return true;
@@ -304,5 +303,5 @@
     private static void showWarningMessage(final String msg) {
         if (msg != null) {
-            Main.warn(msg.replace("<html>", "").replace("</html>", ""));
+            Logging.warn(msg.replace("<html>", "").replace("</html>", ""));
             GuiHelper.runInEDT(new Runnable() {
                 @Override
@@ -318,5 +317,5 @@
     private static void showErrorMessage(final String msg) {
         if (msg != null) {
-            Main.error(msg.replace("<html>", "").replace("</html>", ""));
+            Logging.error(msg.replace("<html>", "").replace("</html>", ""));
             GuiHelper.runInEDT(new Runnable() {
                 @Override
@@ -332,5 +331,5 @@
     private static void showInfoMessage(final String msg) {
         if (msg != null) {
-            Main.info(msg.replace("<html>", "").replace("</html>", ""));
+            Logging.info(msg.replace("<html>", "").replace("</html>", ""));
             GuiHelper.runInEDT(new Runnable() {
                 @Override
