Changeset 33768 in osm for applications/editors/josm
- Timestamp:
- 2017-11-04T19:08:56+01:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/public_transport/src/org/openstreetmap/josm/plugins/public_transport/actions/RoutePatternAction.java
r33767 r33768 1828 1828 private double calcOffset(StopReference sr, Vector<SegmentMetric> segmentMetrics) { 1829 1829 double offset = 0; 1830 if ((sr.index + 1) / 2 < segmentMetrics.size()) { 1830 int size = segmentMetrics.size(); 1831 if ((sr.index + 1) / 2 < size) { 1831 1832 offset = segmentMetrics.elementAt((sr.index + 1) / 2).distance; 1832 1833 if (sr.index % 2 == 0) 1833 1834 offset += sr.pos; 1834 } else 1835 offset = segmentMetrics.elementAt(s egmentMetrics.size()- 1).distance1836 egmentMetrics.size()- 1).length;1837 1835 } else if (size > 0) { 1836 offset = segmentMetrics.elementAt(size - 1).distance 1837 + segmentMetrics.elementAt(size - 1).length; 1838 } 1838 1839 return offset; 1839 1840 }
Note:
See TracChangeset
for help on using the changeset viewer.