From d6755324ad972002c316bbf1ac6e54129be0ed6d Mon Sep 17 00:00:00 2001 From: Job Bolle Date: Fri, 3 Nov 2017 13:03:39 +0100 Subject: [PATCH] Merge branch 'analyzer-issues' again These are da2f747 and 2bd99d0 from PR #270 --- src/Core/GuiDisplayGen.m | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Core/GuiDisplayGen.m b/src/Core/GuiDisplayGen.m index 306e307cc..bd7287424 100644 --- a/src/Core/GuiDisplayGen.m +++ b/src/Core/GuiDisplayGen.m @@ -1782,7 +1782,6 @@ - (void) drawStarChart:(GLfloat)x :(GLfloat)y :(GLfloat)z :(GLfloat) alpha :(BOO (textRow-1) * MAIN_GUI_ROW_HEIGHT * pixelRatio); OOSystemID target = [PLAYER targetSystemID]; - NSString *targetName = [UNIVERSE getSystemName:target]; double dx, dy; // get a list of systems marked as contract destinations @@ -1893,10 +1892,9 @@ - (void) drawStarChart:(GLfloat)x :(GLfloat)y :(GLfloat)z :(GLfloat) alpha :(BOO { [self drawAdvancedNavArrayAtX:x+hoffset y:y+voffset z:z alpha:alpha usingRoute:nil optimizedBy:OPTIMIZED_BY_NONE zoom: zoom]; } - NSPoint targetCoordinates = (NSPoint){0,0}; if (!routeExists) { - targetCoordinates = [systemManager getCoordinatesForSystem:target inGalaxy:galaxy_id]; + NSPoint targetCoordinates = [systemManager getCoordinatesForSystem:target inGalaxy:galaxy_id]; distance = distanceBetweenPlanetPositions(targetCoordinates.x,targetCoordinates.y,galaxy_coordinates.x,galaxy_coordinates.y); if (distance == 0.0) @@ -2234,7 +2232,7 @@ - (void) drawStarChart:(GLfloat)x :(GLfloat)y :(GLfloat)z :(GLfloat) alpha :(BOO tab_stops[2] = 288; [self overrideTabs:tab_stops from:kGuiChartTraveltimeTabs length:3]; [self setTabStops:tab_stops]; - targetName = [[UNIVERSE getSystemName:target] retain]; + NSString *targetName = [[UNIVERSE getSystemName:target] retain]; // distance-f & est-travel-time-f are identical between short & long range charts in standard Oolite, however can be alterered separately via OXPs NSString *travelDistLine = @"";