Changeset 13319 in josm
- Timestamp:
- 2018-01-14T04:17:16+01:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/Main.java
r13316 r13319 13 13 import java.util.EnumSet; 14 14 import java.util.HashMap; 15 import java.util.Iterator;16 15 import java.util.List; 17 16 import java.util.Map; … … 415 414 if ((newValue == null ^ oldValue == null) 416 415 || (newValue != null && oldValue != null && !Objects.equals(newValue.toCode(), oldValue.toCode()))) { 417 Iterator<WeakReference<ProjectionChangeListener>> it = listeners.iterator(); 418 while (it.hasNext()) { 419 WeakReference<ProjectionChangeListener> wr = it.next(); 420 ProjectionChangeListener listener = wr.get(); 421 if (listener == null) { 422 it.remove(); 423 continue; 424 } 425 listener.projectionChanged(oldValue, newValue); 426 } 416 listeners.removeIf(x -> x.get() == null); 417 listeners.forEach(x -> x.get().projectionChanged(oldValue, newValue)); 427 418 if (newValue != null && oldBounds != null && main != null) { 428 419 main.restoreOldBounds(oldBounds);
Note:
See TracChangeset
for help on using the changeset viewer.