Changeset 237 in josm for src/org/openstreetmap/josm/plugins


Ignore:
Timestamp:
2007-05-17T03:20:42+02:00 (18 years ago)
Author:
framm
Message:

Major download dialog reorg (now uses tabs, modified World Chooser with keyboard control, plugin interface allows adding of tabs)
New Userlist dialog shows people having edited selected items

Location:
src/org/openstreetmap/josm/plugins
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/org/openstreetmap/josm/plugins/Plugin.java

    r199 r237  
    88import java.net.URL;
    99import java.net.URLClassLoader;
     10import java.util.List;
    1011
    1112import org.openstreetmap.josm.Main;
    1213import org.openstreetmap.josm.gui.MapFrame;
     14import org.openstreetmap.josm.gui.download.DownloadSelection;
    1315import org.openstreetmap.josm.gui.preferences.PreferenceSetting;
    1416
     
    7577         * if any available.
    7678         */
    77         public PreferenceSetting getPreferenceSetting() {return null;}
     79        public PreferenceSetting getPreferenceSetting() { return null; }
    7880       
     81        /**
     82         * Called in the download dialog to give the plugin a chance to modify the list
     83         * of bounding box selectors.
     84         */
     85        public void addDownloadSelection(List<DownloadSelection> list) {}
    7986       
    8087        /**
  • src/org/openstreetmap/josm/plugins/PluginProxy.java

    r168 r237  
    11package org.openstreetmap.josm.plugins;
    22
     3import java.util.List;
     4
    35import org.openstreetmap.josm.gui.MapFrame;
     6import org.openstreetmap.josm.gui.download.DownloadSelection;
    47import org.openstreetmap.josm.gui.preferences.PreferenceSetting;
    58
     
    4144                }
    4245    }
     46       
     47        @Override public void addDownloadSelection(List<DownloadSelection> list) {
     48                try {
     49                        plugin.getClass().getMethod("getDownloadSelection", List.class).invoke(plugin);
     50                } catch (NoSuchMethodException e) {
     51                        // ignore
     52                } catch (Exception e) {
     53                        throw new PluginException(this, info.name, e);
     54                }
     55        }
    4356}
Note: See TracChangeset for help on using the changeset viewer.