diff --git a/android/res/values/donottranslate.xml b/android/res/values/donottranslate.xml index 0f3fea42f9..0131b524c3 100644 --- a/android/res/values/donottranslate.xml +++ b/android/res/values/donottranslate.xml @@ -49,6 +49,7 @@ TtsInfoLink https://support.maps.me/hc/en-us/articles/208628985-How-can-I-check-TTS-settings-on-my-Android-device- AutoDownloadMap + BackupBookmarks 3D 3DBuildings TrackScreen diff --git a/android/res/xml/prefs_main.xml b/android/res/xml/prefs_main.xml index 3fe765045e..85b20fca4d 100644 --- a/android/res/xml/prefs_main.xml +++ b/android/res/xml/prefs_main.xml @@ -31,21 +31,25 @@ android:key="@string/pref_autodownload" android:title="@string/autodownload" android:order="4"/> + + android:order="6"/> + android:order="7"/> + android:order="8"> 0) { diff --git a/android/src/com/mapswithme/maps/settings/SettingsPrefsFragment.java b/android/src/com/mapswithme/maps/settings/SettingsPrefsFragment.java index 73ced9ef98..ac884a1aad 100644 --- a/android/src/com/mapswithme/maps/settings/SettingsPrefsFragment.java +++ b/android/src/com/mapswithme/maps/settings/SettingsPrefsFragment.java @@ -292,6 +292,7 @@ public class SettingsPrefsFragment extends BaseXmlSettingsFragment initZoomPrefsCallbacks(); initMapStylePrefsCallbacks(); initAutoDownloadPrefsCallbacks(); + initBackupBookmarksPrefsCallbacks(); initLargeFontSizePrefsCallbacks(); initTransliterationPrefsCallbacks(); init3dModePrefsCallbacks(); @@ -749,6 +750,22 @@ public class SettingsPrefsFragment extends BaseXmlSettingsFragment }); } + private void initBackupBookmarksPrefsCallbacks() + { + TwoStatePreference pref = (TwoStatePreference)findPreference(getString(R.string.pref_backupbookmarks)); + if (pref == null) + return; + + pref.setChecked(false/* TODO: read setting from the core*/); + pref.setOnPreferenceChangeListener( + (preference, newValue) -> + { + boolean value = (Boolean) newValue; + //TODO: set setting here. + return true; + }); + } + private void initMapStylePrefsCallbacks() { final ListPreference pref = (ListPreference)findPreference(getString(R.string.pref_map_style)); diff --git a/android/src/com/mapswithme/util/Config.java b/android/src/com/mapswithme/util/Config.java index d85a9ad5df..d45994f782 100644 --- a/android/src/com/mapswithme/util/Config.java +++ b/android/src/com/mapswithme/util/Config.java @@ -22,7 +22,6 @@ public final class Config private static final String KEY_TTS_LANGUAGE = "TtsLanguage"; private static final String KEY_DOWNLOADER_AUTO = "AutoDownloadEnabled"; - private static final String KEY_PREF_ZOOM_BUTTONS = "ZoomButtonsEnabled"; static final String KEY_PREF_STATISTICS = "StatisticsEnabled"; private static final String KEY_PREF_USE_GS = "UseGoogleServices";