Skip to content

Commit

Permalink
Hide Location Sharing
Browse files Browse the repository at this point in the history
  • Loading branch information
Claire1817 authored Mar 9, 2022
1 parent d3c11eb commit 12dd29c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
7 changes: 5 additions & 2 deletions vector/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,11 @@ android {
// Indicates whether or not threading support is enabled
buildConfigField "Boolean", "THREADING_ENABLED", "${isThreadingEnabled}"

buildConfigField "Boolean", "enableLocationSharing", "true"
buildConfigField "String", "mapTilerKey", "\"fU3vlMsMn4Jb6dnEIFsx\""
// Tchap: Disable Location Sharing
def enableLocationSharing = false
buildConfigField "Boolean", "enableLocationSharing", "${enableLocationSharing}"
resValue "bool", "enable_location_sharing", "${enableLocationSharing}"
buildConfigField "String", "mapTilerKey", "\"\""

// Tchap: Key Backup is not supported
buildConfigField "Boolean", "IS_KEY_BACKUP_SUPPORTED", "false"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1001,7 +1001,8 @@ class VectorPreferences @Inject constructor(private val context: Context) {
}

fun labsRenderLocationsInTimeline(): Boolean {
return defaultPrefs.getBoolean(SETTINGS_LABS_RENDER_LOCATIONS_IN_TIMELINE, true)
// Tchap: disable render locations in timeline
return defaultPrefs.getBoolean(SETTINGS_LABS_RENDER_LOCATIONS_IN_TIMELINE, BuildConfig.enableLocationSharing)
}

fun areThreadMessagesEnabled(): Boolean {
Expand Down
2 changes: 1 addition & 1 deletion vector/src/main/res/xml/vector_settings_labs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
android:title="@string/labs_auto_report_uisi" />

<im.vector.app.core.preference.VectorSwitchPreference
android:defaultValue="true"
android:defaultValue="@bool/enable_location_sharing"
android:key="SETTINGS_LABS_RENDER_LOCATIONS_IN_TIMELINE"
android:title="@string/labs_render_locations_in_timeline" />

Expand Down

0 comments on commit 12dd29c

Please sign in to comment.