Changeset 36142 in osm for applications/editors/josm/plugins/reltoolbox/src
- Timestamp:
- 2023-09-18T19:27:57+02:00 (14 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/reltoolbox/src/relcontext/actions/ReconstructPolygonAction.java
r36136 r36142 64 64 boolean wont = false; 65 65 for (RelationMember m : r.getMembers()) { 66 if (m.isWay() && m.getWay().getReferrers().size() == 1) {66 if (m.isWay()) { 67 67 ways.add(m.getWay()); 68 68 } else { … … 157 157 tags.remove("type"); 158 158 159 // then delete ways that are not relevant (do not take part in other relations o fhave strange tags)159 // then delete ways that are not relevant (do not take part in other relations or have strange tags) 160 160 Way candidateWay = null; 161 161 for (Way w : p.ways) { 162 if (w.getReferrers(). equals(relations)) {162 if (w.getReferrers().size() == 1) { 163 163 // check tags that remain 164 164 Set<String> keys = new HashSet<>(w.keySet()); … … 192 192 // only delete the relation if it hasn't been re-used 193 193 if (!relationReused) { 194 commands.add(relationDeleteCommand); 194 // The relation needs to be deleted first, so that undo/redo continue to work properly 195 commands.add(0, relationDeleteCommand); 195 196 } 196 197
Note:
See TracChangeset
for help on using the changeset viewer.