Changeset 33748 in osm


Ignore:
Timestamp:
2017-10-30T20:10:22+01:00 (7 years ago)
Author:
holgermappt
Message:

Update for JOSM deprecated API.

Location:
applications/editors/josm/plugins/imagery_cachexport
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/imagery_cachexport/build.xml

    r33073 r33748  
    1111    <property name="commit.message" value="Commit message"/>
    1212    <!-- enter the *lowest* JOSM version this plugin is currently compatible with -->
    13     <property name="plugin.main.version" value="11197"/>
     13    <property name="plugin.main.version" value="12847"/>
    1414
    1515    <!-- Configure these properties (replace "..." accordingly).
  • applications/editors/josm/plugins/imagery_cachexport/src/org/openstreetmap/josm/plugins/imagery_cachexport/AbstractImageryCacheExportAction.java

    r33073 r33748  
    2323import org.openstreetmap.josm.Main;
    2424import org.openstreetmap.josm.data.cache.BufferedImageCacheEntry;
     25import org.openstreetmap.josm.gui.MainApplication;
    2526import org.openstreetmap.josm.gui.Notification;
    2627import org.openstreetmap.josm.gui.PleaseWaitRunnable;
     
    255256                                  cacheKeyPrefix, keySet, objects);
    256257        if (task != null) {
    257             Main.worker.submit(task);
     258            MainApplication.worker.submit(task);
    258259        }
    259260    }
  • applications/editors/josm/plugins/imagery_cachexport/src/org/openstreetmap/josm/plugins/imagery_cachexport/ImageryTileExportDialog.java

    r33073 r33748  
    2020import org.openstreetmap.josm.gui.ExtendedDialog;
    2121import org.openstreetmap.josm.gui.widgets.JosmTextField;
     22import org.openstreetmap.josm.spi.preferences.Config;
    2223import org.openstreetmap.josm.tools.GBC;
    2324
     
    5556        exportDir.setHint(tr("file system path"));
    5657        exportDir.setToolTipText(tr("File system path the tiles are exported to."));
    57         exportDir.setText(Main.pref.get(EXPORT_DIR_PNAME, null));
     58        exportDir.setText(Config.getPref().get(EXPORT_DIR_PNAME, null));
    5859        exportDir.getDocument().addDocumentListener(new DocumentListener() {
    5960            @Override
     
    7576
    7677        appendName.setToolTipText(tr("Append cache name to export directory."));
    77         appendName.setSelected(Main.pref.getBoolean(APPEND_NAME_PNAME));
     78        appendName.setSelected(Config.getPref().getBoolean(APPEND_NAME_PNAME));
    7879        ChangeListener appendNameChangeListener = new ChangeListener() {
    7980            @Override
     
    213214     */
    214215    public void storePrefs() {
    215         Main.pref.put(EXPORT_DIR_PNAME, exportDir.getText());
    216         Main.pref.put(APPEND_NAME_PNAME, appendName.isSelected());
     216        Config.getPref().put(EXPORT_DIR_PNAME, exportDir.getText());
     217        Config.getPref().putBoolean(APPEND_NAME_PNAME, appendName.isSelected());
    217218    }
    218219}
Note: See TracChangeset for help on using the changeset viewer.