Changeset 35132 in osm for applications/editors/josm/plugins/cadastre-fr
- Timestamp:
- 2019-09-26T15:31:53+02:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/cadastre-fr/src/org/openstreetmap/josm/plugins/fr/cadastre/actions/mapmode/Address.java
r34458 r35132 18 18 import java.awt.event.WindowEvent; 19 19 import java.util.ArrayList; 20 import java.util.Arrays; 20 21 import java.util.Collection; 21 22 import java.util.Collections; … … 278 279 279 280 private void addStreetNameOrRelation(OsmPrimitive osm, Collection<Command> cmds) { 281 DataSet ds = OsmDataManager.getInstance().getEditDataSet(); 280 282 if (Config.getPref().getBoolean("cadastrewms.addr.dontUseRelation", false)) { 281 cmds.add(new ChangePropertyCommand(osm, tagHouseStreet, inputStreet.getText())); 283 Map<String, String> tags = new HashMap<>(); 284 tags.put(tagHouseStreet, inputStreet.getText()); 285 cmds.add(new ChangePropertyCommand(ds, Arrays.asList(osm), tags)); 282 286 } else if (selectedWay != null) { 283 287 Relation selectedRelation = findRelationAddr(selectedWay); … … 295 299 newRel.addMember(new RelationMember(relationAddrStreetRole, selectedWay)); 296 300 newRel.addMember(new RelationMember(relationMemberHouse, osm)); 297 cmds.add(new AddCommand( OsmDataManager.getInstance().getEditDataSet(), newRel));301 cmds.add(new AddCommand(ds, newRel)); 298 302 } 299 303 }
Note:
See TracChangeset
for help on using the changeset viewer.