Fix navigation

This commit is contained in:
Victor Shcherb 2012-11-10 22:03:04 +01:00
parent 59c8b5d39c
commit a7b01c686c

View file

@ -46,10 +46,12 @@ public class RouteSegmentResult {
} }
public void copyPreattachedRoutes(RouteSegmentResult toCopy, int shift) { public void copyPreattachedRoutes(RouteSegmentResult toCopy, int shift) {
if(toCopy.preAttachedRoutes != null) {
int l = toCopy.preAttachedRoutes.length - shift; int l = toCopy.preAttachedRoutes.length - shift;
preAttachedRoutes = new RouteSegmentResult[l][]; preAttachedRoutes = new RouteSegmentResult[l][];
System.arraycopy(toCopy.preAttachedRoutes, shift, preAttachedRoutes, 0, l); System.arraycopy(toCopy.preAttachedRoutes, shift, preAttachedRoutes, 0, l);
} }
}
public RouteSegmentResult[] getPreAttachedRoutes(int routeInd) { public RouteSegmentResult[] getPreAttachedRoutes(int routeInd) {
int st = Math.abs(routeInd - startPointIndex); int st = Math.abs(routeInd - startPointIndex);