Fix "exit confirmation dialog is displayed every time after screen was flipped"

This commit is contained in:
nazar-kutz 2021-01-18 13:18:51 +02:00
parent f26a547103
commit d5d32b7674

View file

@ -658,6 +658,7 @@ public class OnlineRoutingEngineFragment extends BaseOsmAndFragment {
}
private void restoreState(@NonNull Bundle savedState) {
editedEngineKey = savedState.getString(EngineParameter.KEY.name());
initEngine = createInitStateEngine();
String typeKey = savedState.getString(ENGINE_TYPE_KEY);
EngineType type = EngineType.getTypeByName(typeKey);
@ -671,7 +672,6 @@ public class OnlineRoutingEngineFragment extends BaseOsmAndFragment {
customVehicleKey = savedState.getString(ENGINE_CUSTOM_VEHICLE_KEY);
selectedLocation = ExampleLocation.valueOf(savedState.getString(EXAMPLE_LOCATION_KEY));
appMode = ApplicationMode.valueOfStringKey(savedState.getString(APP_MODE_KEY), null);
editedEngineKey = savedState.getString(EngineParameter.KEY.name());
}
private void initState() {