Changeset 15378 in josm for trunk/src/org
- Timestamp:
- 2019-09-26T22:40:50+02:00 (5 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/DataSet.java
r14835 r15378 930 930 private void fireEventToListeners(AbstractDatasetChangedEvent event) { 931 931 for (DataSetListener listener : listeners) { 932 Logging.trace("Firing {0} to {1} (dataset)", event, listener); 932 933 event.fire(listener); 933 934 } -
trunk/src/org/openstreetmap/josm/data/osm/event/DatasetEventManager.java
r13434 r15378 17 17 import org.openstreetmap.josm.gui.layer.MainLayerManager.ActiveLayerChangeEvent; 18 18 import org.openstreetmap.josm.gui.layer.MainLayerManager.ActiveLayerChangeListener; 19 import org.openstreetmap.josm.tools.Logging; 19 20 20 21 /** … … 197 198 for (ListenerInfo listener: listeners) { 198 199 if (!listener.consolidate) { 200 Logging.trace("Firing {0} to {1} (normal)", event, listener.listener); 199 201 event.fire(listener.listener); 200 202 } … … 205 207 for (ListenerInfo listener: listeners) { 206 208 if (listener.consolidate) { 209 Logging.trace("Firing {0} to {1} (consolidated)", event, listener.listener); 207 210 event.fire(listener.listener); 208 211 } -
trunk/src/org/openstreetmap/josm/gui/dialogs/relation/MemberTableModel.java
r15278 r15378 174 174 @Override 175 175 public void wayNodesChanged(WayNodesChangedEvent event) { 176 // ignore 176 if (hasMembersReferringTo(Collections.singleton(event.getChangedWay()))) { 177 // refresh connectivity 178 for (int i = 0; i < members.size(); i++) { 179 fireTableCellUpdated(i, 2 /* the column with the connectivity arrow */); 180 } 181 } 177 182 } 178 183 … … 666 671 if (primitives == null || primitives.isEmpty()) 667 672 return false; 668 Set<OsmPrimitive> referrers = new HashSet<>(); 669 for (RelationMember member : members) { 670 referrers.add(member.getMember()); 671 } 672 for (OsmPrimitive referred : primitives) { 673 if (referrers.contains(referred)) 674 return true; 675 } 676 return false; 673 Set<OsmPrimitive> referrers = members.stream().map(RelationMember::getMember).collect(Collectors.toSet()); 674 return primitives.stream().anyMatch(referrers::contains); 677 675 } 678 676
Note:
See TracChangeset
for help on using the changeset viewer.