mapbox-navigation-ios icon indicating copy to clipboard operation
mapbox-navigation-ios copied to clipboard

Fix the issue of invisible exit views from night mode to day mode.

Open ShanMa1991 opened this issue 3 years ago • 2 comments

Description

This Pr is to fix the issue that when two continuous active navigation using different styles, the exit views in the second session may be invisible.

Implementation

https://github.com/mapbox/mapbox-navigation-ios/pull/3930 introduced the function to record the platform related style. If there're two active active navigation sessions, If the second active navigation session is using the customized NavigationMapView in its NavigationOptions which has the same style as in the NavigationOptions , and hasn't change its style from the start, the shields may use the style from the previous active navigation session on current platform. It would lead to the invisible Exit Views on the instruction label of the second active navigation session.

The root cause is that we only update the shield when the style is changed during current navigation session as in https://github.com/mapbox/mapbox-navigation-ios/blob/b1bccccc17bfb3bbbf54397c4e94e405752852da/Sources/MapboxNavigation/NavigationViewController.swift#L1073-L1078

Screenshots or Gifs

ShanMa1991 avatar Oct 11 '22 17:10 ShanMa1991

Breaking Changes in MapboxCoreNavigation

Breaking API Changes

RouteLegProgress

  • removed method: init(leg:stepIndex:spokenInstructionIndex:) in RouteLegProgress

RouteProgress

  • removed method: init(route:options:legIndex:spokenInstructionIndex:) in RouteProgress

Breaking Changes in MapboxCoreNavigation

Breaking API Changes

RouteLegProgress

  • removed method: init(leg:stepIndex:spokenInstructionIndex:) in RouteLegProgress

RouteProgress

  • removed method: init(route:options:legIndex:spokenInstructionIndex:) in RouteProgress

Breaking Changes in MapboxCoreNavigation

Breaking API Changes

RouteLegProgress

  • removed method: init(leg:stepIndex:spokenInstructionIndex:) in RouteLegProgress

RouteProgress

  • removed method: init(route:options:legIndex:spokenInstructionIndex:) in RouteProgress