Index: trunk/src/org/openstreetmap/josm/data/preferences/AbstractProperty.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/preferences/AbstractProperty.java	(revision 3730)
+++ trunk/src/org/openstreetmap/josm/data/preferences/AbstractProperty.java	(revision 3730)
@@ -0,0 +1,23 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.data.preferences;
+
+import org.openstreetmap.josm.Main;
+
+/**
+ * captures the common functionality of preference properties
+ */
+public class AbstractProperty {
+    protected final String key;
+
+    public AbstractProperty(String key) {
+        this.key = key;
+    }
+
+    public String getKey() {
+        return key;
+    }
+
+    public boolean isSet() {
+        return Main.pref.hasKey(key);
+    }
+}
Index: trunk/src/org/openstreetmap/josm/data/preferences/BooleanProperty.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/preferences/BooleanProperty.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/data/preferences/BooleanProperty.java	(revision 3730)
@@ -4,11 +4,10 @@
 import org.openstreetmap.josm.Main;
 
-public class BooleanProperty {
+public class BooleanProperty extends AbstractProperty {
 
-    private final String key;
-    private final boolean defaultValue;
+    protected final boolean defaultValue;
 
     public BooleanProperty(String key, boolean defaultValue) {
-        this.key = key;
+        super(key);
         this.defaultValue = defaultValue;
     }
@@ -22,11 +21,6 @@
     }
 
-    public String getKey() {
-        return key;
-    }
-
     public boolean isDefaultValue() {
         return defaultValue;
     }
-
 }
Index: trunk/src/org/openstreetmap/josm/data/preferences/CollectionProperty.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/preferences/CollectionProperty.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/data/preferences/CollectionProperty.java	(revision 3730)
@@ -6,10 +6,9 @@
 import org.openstreetmap.josm.Main;
 
-public class CollectionProperty {
-    private final String key;
-    private final Collection<String> defaultValue;
+public class CollectionProperty extends AbstractProperty {
+    protected final Collection<String> defaultValue;
 
     public CollectionProperty(String key, Collection<String> defaultValue) {
-        this.key = key;
+        super(key);
         this.defaultValue = defaultValue;
     }
@@ -23,8 +22,4 @@
     }
 
-    public String getKey() {
-        return key;
-    }
-
     public Collection<String> getDefaultValue() {
         return defaultValue;
Index: trunk/src/org/openstreetmap/josm/data/preferences/IntegerProperty.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/preferences/IntegerProperty.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/data/preferences/IntegerProperty.java	(revision 3730)
@@ -4,11 +4,10 @@
 import org.openstreetmap.josm.Main;
 
-public class IntegerProperty {
+public class IntegerProperty extends AbstractProperty {
 
-    private final String key;
-    private final int defaultValue;
+    protected final int defaultValue;
 
     public IntegerProperty(String key, int defaultValue) {
-        this.key = key;
+        super(key);
         this.defaultValue = defaultValue;
     }
@@ -38,8 +37,4 @@
     }
 
-    public String getKey() {
-        return key;
-    }
-
     public int getDefaultValue() {
         return defaultValue;
Index: trunk/src/org/openstreetmap/josm/data/preferences/StringProperty.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/preferences/StringProperty.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/data/preferences/StringProperty.java	(revision 3730)
@@ -4,11 +4,10 @@
 import org.openstreetmap.josm.Main;
 
-public class StringProperty {
+public class StringProperty extends AbstractProperty {
 
-    private final String key;
-    private final String defaultValue;
+    protected final String defaultValue;
 
     public StringProperty(String key, String defaultValue) {
-        this.key = key;
+        super(key);
         this.defaultValue = defaultValue;
     }
@@ -22,8 +21,4 @@
     }
 
-    public String getKey() {
-        return key;
-    }
-
     public String getDefaultValue() {
         return defaultValue;
Index: trunk/src/org/openstreetmap/josm/plugins/PluginHandler.java
===================================================================
--- trunk/src/org/openstreetmap/josm/plugins/PluginHandler.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/plugins/PluginHandler.java	(revision 3730)
@@ -29,5 +29,4 @@
 import java.util.Set;
 import java.util.Map.Entry;
-import java.util.TreeMap;
 import java.util.TreeSet;
 import java.util.concurrent.ExecutionException;
@@ -59,4 +58,5 @@
 import org.openstreetmap.josm.gui.progress.NullProgressMonitor;
 import org.openstreetmap.josm.gui.progress.ProgressMonitor;
+import org.openstreetmap.josm.io.remotecontrol.RemoteControl;
 import org.openstreetmap.josm.tools.CheckParameterUtil;
 import org.openstreetmap.josm.tools.GBC;
@@ -70,26 +70,82 @@
 public class PluginHandler {
 
-    /* deprecated plugins that are removed on start
-       key - plugin name; value - explanation for deprecation (optional, can be null) */
-    public final static Map<String, String> DEPRECATED_PLUGINS = new TreeMap<String, String>();
+    /* deprecated plugins that are removed on start */
+    public final static Collection<DeprecatedPlugin> DEPRECATED_PLUGINS;
     static {
         String IN_CORE = tr("integrated into main program");
-        for (String[] depr : new String[][] {
-            {"mappaint", IN_CORE}, {"unglueplugin", IN_CORE},
-            {"lang-de", IN_CORE}, {"lang-en_GB", IN_CORE}, {"lang-fr", IN_CORE},
-            {"lang-it", IN_CORE}, {"lang-pl", IN_CORE}, {"lang-ro", IN_CORE},
-            {"lang-ru", IN_CORE}, {"ewmsplugin", IN_CORE}, {"ywms", IN_CORE},
-            {"tways-0.2", IN_CORE},
-            {"geotagged", IN_CORE},
-            {"landsat", tr("replaced by {0} plugin","lakewalker")},
-            {"namefinder", IN_CORE},
-            {"waypoints", IN_CORE}, {"slippy_map_chooser", IN_CORE},
-            {"tcx-support", tr("replaced by {0} plugin","dataimport")},
-            {"usertools", IN_CORE},
-            {"AgPifoJ", IN_CORE}, {"utilsplugin", IN_CORE}, {"ghost", IN_CORE},
-            {"validator", IN_CORE}, {"multipoly", IN_CORE},
-            {"remotecontrol", IN_CORE},
-            {"imagery", IN_CORE}, {"slippymap", IN_CORE}, {"wmsplugin", IN_CORE}}) {
-            DEPRECATED_PLUGINS.put(depr[0], depr.length >= 2 ? depr[1] : null);
+
+        class RemotecontrolMigration implements Runnable {
+            public void run() {
+                System.out.println("Migrating remotecontrol plugin...");
+                if (!RemoteControl.PROP_REMOTECONTROL_ENABLED.isSet()) {
+                    System.out.println("  Setting "+RemoteControl.PROP_REMOTECONTROL_ENABLED.getKey()+"=true");
+                    RemoteControl.PROP_REMOTECONTROL_ENABLED.put(true);
+                }
+                System.out.println("...Done.");
+            }
+        }
+
+        DEPRECATED_PLUGINS = Arrays.asList(new DeprecatedPlugin[] {
+            new DeprecatedPlugin("mappaint", IN_CORE),
+            new DeprecatedPlugin("unglueplugin", IN_CORE),
+            new DeprecatedPlugin("lang-de", IN_CORE),
+            new DeprecatedPlugin("lang-en_GB", IN_CORE),
+            new DeprecatedPlugin("lang-fr", IN_CORE),
+            new DeprecatedPlugin("lang-it", IN_CORE),
+            new DeprecatedPlugin("lang-pl", IN_CORE),
+            new DeprecatedPlugin("lang-ro", IN_CORE),
+            new DeprecatedPlugin("lang-ru", IN_CORE),
+            new DeprecatedPlugin("ewmsplugin", IN_CORE),
+            new DeprecatedPlugin("ywms", IN_CORE),
+            new DeprecatedPlugin("tways-0.2", IN_CORE),
+            new DeprecatedPlugin("geotagged", IN_CORE),
+            new DeprecatedPlugin("landsat", tr("replaced by new {0} plugin","lakewalker")),
+            new DeprecatedPlugin("namefinder", IN_CORE),
+            new DeprecatedPlugin("waypoints", IN_CORE),
+            new DeprecatedPlugin("slippy_map_chooser", IN_CORE),
+            new DeprecatedPlugin("tcx-support", tr("replaced by new {0} plugin","dataimport")),
+            new DeprecatedPlugin("usertools", IN_CORE),
+            new DeprecatedPlugin("AgPifoJ", IN_CORE),
+            new DeprecatedPlugin("utilsplugin", IN_CORE),
+            new DeprecatedPlugin("ghost", IN_CORE),
+            new DeprecatedPlugin("validator", IN_CORE),
+            new DeprecatedPlugin("multipoly", IN_CORE),
+            new DeprecatedPlugin("remotecontrol", IN_CORE, new RemotecontrolMigration()),
+            new DeprecatedPlugin("imagery", IN_CORE),
+            new DeprecatedPlugin("slippymap", IN_CORE),
+            new DeprecatedPlugin("wmsplugin", IN_CORE),
+        });
+    }
+
+    public static class DeprecatedPlugin implements Comparable<DeprecatedPlugin> {
+        public String name;
+        // short explanation, can be null
+        public String reason;
+        // migration, can be null
+        private Runnable migration;
+
+        public DeprecatedPlugin(String name) {
+            this.name = name;
+        }
+
+        public DeprecatedPlugin(String name, String reason) {
+            this.name = name;
+            this.reason = reason;
+        }
+
+        public DeprecatedPlugin(String name, String reason, Runnable migration) {
+            this.name = name;
+            this.reason = reason;
+            this.migration = migration;
+        }
+
+        public void migrate() {
+            if (migration != null) {
+                migration.run();
+            }
+        }
+
+        public int compareTo(DeprecatedPlugin o) {
+            return name.compareTo(o.name);
         }
     }
@@ -111,10 +167,11 @@
      */
     private static void filterDeprecatedPlugins(Window parent, Collection<String> plugins) {
-        Set<String> removedPlugins = new TreeSet<String>();
-        for (String p : DEPRECATED_PLUGINS.keySet()) {
-            if (plugins.contains(p)) {
-                plugins.remove(p);
-                Main.pref.removeFromCollection("plugins", p);
-                removedPlugins.add(p);
+        Set<DeprecatedPlugin> removedPlugins = new TreeSet<DeprecatedPlugin>();
+        for (DeprecatedPlugin depr : DEPRECATED_PLUGINS) {
+            if (plugins.contains(depr.name)) {
+                plugins.remove(depr.name);
+                Main.pref.removeFromCollection("plugins", depr.name);
+                removedPlugins.add(depr);
+                depr.migrate();
             }
         }
@@ -132,9 +189,8 @@
         ));
         sb.append("<ul>");
-        for (String name: removedPlugins) {
-            sb.append("<li>").append(name);
-            String explanation = DEPRECATED_PLUGINS.get(name);
-            if (explanation != null) {
-                sb.append(" ("+explanation+")");
+        for (DeprecatedPlugin depr: removedPlugins) {
+            sb.append("<li>").append(depr.name);
+            if (depr.reason != null) {
+                sb.append(" (").append(depr.reason).append(")");
             }
             sb.append("</li>");
Index: trunk/src/org/openstreetmap/josm/plugins/ReadLocalPluginInformationTask.java
===================================================================
--- trunk/src/org/openstreetmap/josm/plugins/ReadLocalPluginInformationTask.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/plugins/ReadLocalPluginInformationTask.java	(revision 3730)
@@ -201,8 +201,8 @@
 
     protected void filterOldPlugins() {
-        for (String p : PluginHandler.DEPRECATED_PLUGINS.keySet()) {
+        for (PluginHandler.DeprecatedPlugin p : PluginHandler.DEPRECATED_PLUGINS) {
             if (canceled)return;
-            if (availablePlugins.containsKey(p)) {
-                availablePlugins.remove(p);
+            if (availablePlugins.containsKey(p.name)) {
+                availablePlugins.remove(p.name);
             }
         }
Index: trunk/src/org/openstreetmap/josm/plugins/ReadRemotePluginInformationTask.java
===================================================================
--- trunk/src/org/openstreetmap/josm/plugins/ReadRemotePluginInformationTask.java	(revision 3729)
+++ trunk/src/org/openstreetmap/josm/plugins/ReadRemotePluginInformationTask.java	(revision 3730)
@@ -295,5 +295,8 @@
     protected List<PluginInformation> filterDeprecatedPlugins(List<PluginInformation> plugins) {
         List<PluginInformation> ret = new ArrayList<PluginInformation>(plugins.size());
-        HashSet<String> deprecatedPluginNames = new HashSet<String>(PluginHandler.DEPRECATED_PLUGINS.keySet());
+        HashSet<String> deprecatedPluginNames = new HashSet<String>();
+        for (PluginHandler.DeprecatedPlugin p : PluginHandler.DEPRECATED_PLUGINS) {
+            deprecatedPluginNames.add(p.name);
+        }
         for (PluginInformation plugin: plugins) {
             if (deprecatedPluginNames.contains(plugin.name)) {
