fix logic of RouteUI::set_color_from_route()

This commit is contained in:
Paul Davis 2016-07-01 18:03:29 -04:00
parent 8a6e9c19d7
commit 176660fff4
1 changed files with 5 additions and 1 deletions

View File

@ -1599,7 +1599,11 @@ RouteUI::route_state_id () const
int
RouteUI::set_color_from_route ()
{
return 0;
if (_route->presentation_info().color_set()) {
return 0; /* nothing to do */
}
return 1; /* pick a color */
}
/** @return true if this name should be used for the route, otherwise false */