Changeset 16624 in osm for applications/editors


Ignore:
Timestamp:
2009-07-21T20:40:31+02:00 (15 years ago)
Author:
jttt
Message:

Make it work without Main.ds

Location:
applications/editors/josm/plugins/remotecontrol
Files:
2 edited

Legend:

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

    r16589 r16624  
    2626                <attribute name="Plugin-Description" value="Let other applications send commands to JOSM."/>
    2727                <attribute name="Plugin-Link" value="http://wiki.openstreetmap.org/index.php/JOSM/Plugins/RemoteControl"/>
    28                 <attribute name="Plugin-Mainversion" value="1813"/>
     28                <attribute name="Plugin-Mainversion" value="1815"/>
    2929                <attribute name="Plugin-Version" value="${version.entry.commit.revision}"/>
    3030            </manifest>
  • applications/editors/josm/plugins/remotecontrol/src/org/openstreetmap/josm/plugins/remotecontrol/RequestProcessor.java

    r16589 r16624  
    148148
    149149                    // find out whether some data has already been downloaded
    150                     Area present = Main.ds.getDataSourceArea();
     150                    Area present = Main.main.getCurrentDataSet().getDataSourceArea();
    151151                    if (present != null && !present.isEmpty()) {
    152152                        Area toDownload = new Area(new Rectangle2D.Double(minlon,minlat,maxlon-minlon,maxlat-minlat));
     
    191191                                }
    192192                            }
    193                             for (Way w : Main.ds.ways) if (ways.contains(w.id)) newSel.add(w);
    194                             for (Node n : Main.ds.nodes) if (nodes.contains(n.id)) newSel.add(n);
    195                             for (Relation r : Main.ds.relations) if (relations.contains(r.id)) newSel.add(r);
    196                             Main.ds.setSelected(newSel);
     193                            for (Way w : Main.main.getCurrentDataSet().ways) if (ways.contains(w.id)) newSel.add(w);
     194                            for (Node n : Main.main.getCurrentDataSet().nodes) if (nodes.contains(n.id)) newSel.add(n);
     195                            for (Relation r : Main.main.getCurrentDataSet().relations) if (relations.contains(r.id)) newSel.add(r);
     196                            Main.main.getCurrentDataSet().setSelected(newSel);
    197197                            if (Main.pref.getBoolean("remotecontrol.permission.change-viewport", true))
    198198                                new AutoScaleAction("selection").actionPerformed(null);
Note: See TracChangeset for help on using the changeset viewer.