Changeset 33564 in osm


Ignore:
Timestamp:
2017-08-27T19:25:32+02:00 (7 years ago)
Author:
donvip
Message:

fix warnings

Location:
applications/editors/josm/plugins/importvec/src/org/openstreetmap/josm/plugins/importvec
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/importvec/src/org/openstreetmap/josm/plugins/importvec/SvgImportTask.java

    r30737 r33564  
    3030import org.openstreetmap.josm.data.projection.Projection;
    3131import org.openstreetmap.josm.data.projection.Projections;
     32import org.openstreetmap.josm.gui.MainApplication;
    3233import org.openstreetmap.josm.gui.PleaseWaitRunnable;
    3334import org.openstreetmap.josm.io.OsmTransferException;
     
    159160    @Override
    160161    protected void realRun() throws IOException, OsmTransferException {
    161         LatLon center = Main.getProjection().eastNorth2latlon(Main.map.mapView.getCenter());
     162        LatLon center = Main.getProjection().eastNorth2latlon(MainApplication.getMap().mapView.getCenter());
    162163        scale = Settings.getScaleNumerator() / Settings.getScaleDivisor() / Math.cos(Math.toRadians(center.lat()));
    163164        this.center = projection.latlon2eastNorth(center);
     
    191192            cmds.add(new AddCommand(w));
    192193        }
    193         Main.main.undoRedo.add(new SequenceCommand("Import primitives", cmds));
     194        MainApplication.undoRedo.add(new SequenceCommand("Import primitives", cmds));
    194195    }
    195196   
  • applications/editors/josm/plugins/importvec/src/org/openstreetmap/josm/plugins/importvec/SvgImporter.java

    r33557 r33564  
    1111import org.openstreetmap.josm.Main;
    1212import org.openstreetmap.josm.actions.ExtensionFileFilter;
     13import org.openstreetmap.josm.gui.MainApplication;
    1314import org.openstreetmap.josm.gui.io.importexport.FileImporter;
    1415import org.openstreetmap.josm.gui.progress.ProgressMonitor;
     
    3233    @Override
    3334    public void importData(List<File> files, ProgressMonitor progressMonitor) throws IOException, IllegalDataException {
    34         if (Main.getLayerManager().getEditLayer() == null) {
     35        if (MainApplication.getLayerManager().getEditLayer() == null) {
    3536            JOptionPane.showMessageDialog(Main.parent, tr("Please open or create data layer before importing"));
    3637            return;
     
    3940        if (dlg.getValue() != 1) return;
    4041        dlg.saveSettings();
    41         Main.worker.submit(new SvgImportTask(files));
     42        MainApplication.worker.submit(new SvgImportTask(files));
    4243    }
    4344}
Note: See TracChangeset for help on using the changeset viewer.