Index: /applications/editors/josm/plugins/undelete/build.xml
===================================================================
--- /applications/editors/josm/plugins/undelete/build.xml	(revision 33834)
+++ /applications/editors/josm/plugins/undelete/build.xml	(revision 33835)
@@ -4,5 +4,5 @@
     <property name="commit.message" value="adapt to core changes (backwards compatible)"/>
     <!-- enter the *lowest* JOSM version this plugin is currently compatible with -->
-    <property name="plugin.main.version" value="10580"/>
+    <property name="plugin.main.version" value="12840"/>
 
     <property name="plugin.author" value="Nakor"/>
Index: /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/Undelete.java
===================================================================
--- /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/Undelete.java	(revision 33834)
+++ /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/Undelete.java	(revision 33835)
@@ -2,5 +2,5 @@
 package org.openstreetmap.josm.plugins.undelete;
 
-import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.gui.MainApplication;
 import org.openstreetmap.josm.gui.MainMenu;
 import org.openstreetmap.josm.plugins.Plugin;
@@ -11,5 +11,5 @@
     public Undelete(PluginInformation info) {
         super(info);
-        MainMenu.addAfter(Main.main.menu.fileMenu, new UndeleteAction(), false, Main.main.menu.updateModified);
+        MainMenu.addAfter(MainApplication.getMenu().fileMenu, new UndeleteAction(), false, MainApplication.getMenu().updateModified);
     }
 }
Index: /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/UndeleteAction.java
===================================================================
--- /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/UndeleteAction.java	(revision 33834)
+++ /applications/editors/josm/plugins/undelete/src/org/openstreetmap/josm/plugins/undelete/UndeleteAction.java	(revision 33835)
@@ -31,4 +31,5 @@
 import org.openstreetmap.josm.data.osm.history.HistoryRelation;
 import org.openstreetmap.josm.data.osm.history.HistoryWay;
+import org.openstreetmap.josm.gui.MainApplication;
 import org.openstreetmap.josm.gui.Notification;
 import org.openstreetmap.josm.gui.history.HistoryLoadTask;
@@ -36,4 +37,5 @@
 import org.openstreetmap.josm.gui.layer.OsmDataLayer;
 import org.openstreetmap.josm.gui.util.GuiHelper;
+import org.openstreetmap.josm.tools.Logging;
 import org.openstreetmap.josm.tools.Shortcut;
 
@@ -66,5 +68,5 @@
 
                         if (h == null) {
-                            Main.warn("Cannot find history for " + type + " " + id);
+                            Logging.warn("Cannot find history for " + type + " " + id);
                             return;
                         }
@@ -171,9 +173,9 @@
                                   : null;
                                 GuiHelper.runInEDT(() -> new Notification(msg).setIcon(JOptionPane.WARNING_MESSAGE).show());
-                                Main.warn(msg);
+                                Logging.warn(msg);
                             }
                         }
                     } catch (Exception t) {
-                        Main.error(t);
+                        Logging.error(t);
                     }
                 }
@@ -184,5 +186,5 @@
             if (parent instanceof Way && !nodes.isEmpty()) {
                 ((Way) parent).setNodes(nodes);
-                Main.map.repaint();
+                MainApplication.getMap().repaint();
             }
             GuiHelper.runInEDT(() -> AutoScaleAction.zoomTo(layer.data.allNonDeletedPrimitives()));
@@ -200,5 +202,5 @@
         if (dialog.showDialog().getValue() != 1)
             return;
-        Main.pref.put("undelete.newlayer", dialog.isNewLayerSelected());
+        Main.pref.putBoolean("undelete.newlayer", dialog.isNewLayerSelected());
         Main.pref.put("undelete.osmid", dialog.getOsmIdsString());
         undelete(dialog.isNewLayerSelected(), dialog.getOsmIds(), null);
@@ -210,10 +212,10 @@
     public void undelete(boolean newLayer, final List<PrimitiveId> ids, final OsmPrimitive parent) {
 
-        Main.info("Undeleting "+ids+(parent == null ? "" : " with parent "+parent));
-
-        OsmDataLayer tmpLayer = Main.getLayerManager().getEditLayer();
+        Logging.info("Undeleting "+ids+(parent == null ? "" : " with parent "+parent));
+
+        OsmDataLayer tmpLayer = MainApplication.getLayerManager().getEditLayer();
         if ((tmpLayer == null) || newLayer) {
             tmpLayer = new OsmDataLayer(new DataSet(), OsmDataLayer.createNewName(), null);
-            Main.getLayerManager().addLayer(tmpLayer);
+            MainApplication.getLayerManager().addLayer(tmpLayer);
         }
 
@@ -225,6 +227,6 @@
         }
 
-        Main.worker.execute(task);
-        Main.worker.submit(new Worker(parent, layer, ids));
+        MainApplication.worker.execute(task);
+        MainApplication.worker.submit(new Worker(parent, layer, ids));
     }
 }
