diff --git a/OsmAnd/src/net/osmand/plus/OsmandSettings.java b/OsmAnd/src/net/osmand/plus/OsmandSettings.java index 58c6291e75..5791c91e9a 100644 --- a/OsmAnd/src/net/osmand/plus/OsmandSettings.java +++ b/OsmAnd/src/net/osmand/plus/OsmandSettings.java @@ -469,6 +469,9 @@ public class OsmandSettings { } + public final OsmandPreference PREV_APPLICATION_MODE = new EnumIntPreference( + "prev_application_mode", ApplicationMode.DEFAULT, true, false, ApplicationMode.values()); + // this value string is synchronized with settings_pref.xml preference name // cache of metrics constants as they are used very often public final OsmandPreference METRIC_SYSTEM = new EnumIntPreference( diff --git a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java index 153211d504..54297d412e 100644 --- a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java +++ b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java @@ -471,6 +471,7 @@ public class MapActivityActions implements DialogProvider { } ApplicationMode mode = getAppMode(buttons, settings); // change global settings + settings.PREV_APPLICATION_MODE.set(settings.APPLICATION_MODE.get()); boolean changed = settings.APPLICATION_MODE.set(mode); if (changed) { mapActivity.updateApplicationModeSettings();