heremaps / here-android-sdk-examples

Java-based projects using the HERE SDK for Android.
Apache License 2.0
146 stars 191 forks source link

Bug: FtcrNavigationManager the language changes after reroute in listener #477

Open Strikelon opened 2 years ago

Strikelon commented 2 years ago

Describe the bug We use FtcrNavigationManager, before calculating new route, I create routeOptions with languafe French. After route is calculated, and navigation is started, everything is ok, the language is French. But we listen a reroute event in the navigation listener, and when it comes, and I start the navigation with the new route from the listener, it speaks with English Language.

private val routeOptions = FTCRRouteOptions().apply {
    setUseTraffic(true)
    routeType = FTCRRouteOptions.Type.FASTEST
    transportMode = FTCRRouteOptions.TransportMode.CAR
    addParameter(LANGUAGE_ROUTE_OPTIONS_KEY, LANGUAGE_ROUTE_OPTIONS_FRANCE)
    addParameter(VEHICLE_TYPE_PARAMETR_TITLE, VEHICLE_TYPE_PARAMETR_VALUE)
}

Steps To Reproduce Steps to reproduce the behavior: 1) create private val routeOptions = FTCRRouteOptions().apply { setUseTraffic(true) routeType = FTCRRouteOptions.Type.FASTEST transportMode = FTCRRouteOptions.TransportMode.CAR addParameter("language", "fr-fr") addParameter("algopts", "vehicleType:taxi") } 2) calculate route 3) add FTCRNavigationManager.FTCRNavigationManagerListener to navigator 4) start navigation, language is French it is ok 5) deviate from the route 6) get new route in event onRerouteEnd in FTCRNavigationManager.FTCRNavigationManagerListener 7) start navigation with new route 8) The language is English, not French, I think because all FTCRRouteOptions skips

Expected behavior language is French and other FTCRRouteOptions are saved during reroute in listener

NazarKacharaba commented 2 years ago

Hi @Strikelon Thanks for reporting this issue, it will be fixed in the 3.20 release(Feb 2022).