diff --git a/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt b/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt index 68a3badd1a..cb7f637536 100644 --- a/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt +++ b/vector/src/main/java/im/vector/app/features/location/LocationSharingFragment.kt @@ -133,7 +133,7 @@ class LocationSharingFragment @Inject constructor( private fun initOptionsPicker() { // TODO // change the options dynamically depending on the current chosen location - views.shareLocationOptionsPicker.setOptions(LocationSharingOption.USER_CURRENT) + views.shareLocationOptionsPicker.render(LocationSharingOption.USER_CURRENT) views.shareLocationOptionsPicker.optionPinned.debouncedClicks { viewModel.handle(LocationSharingAction.OnShareLocation) } diff --git a/vector/src/main/java/im/vector/app/features/location/option/LocationSharingOptionPickerView.kt b/vector/src/main/java/im/vector/app/features/location/option/LocationSharingOptionPickerView.kt index 24ab2529d7..1aea1ff613 100644 --- a/vector/src/main/java/im/vector/app/features/location/option/LocationSharingOptionPickerView.kt +++ b/vector/src/main/java/im/vector/app/features/location/option/LocationSharingOptionPickerView.kt @@ -58,7 +58,7 @@ class LocationSharingOptionPickerView @JvmOverloads constructor( applyBackground() } - fun setOptions(vararg options: LocationSharingOption) { + fun render(vararg options: LocationSharingOption) { val optionsNumber = options.toSet().size val isPinnedVisible = options.contains(LocationSharingOption.PINNED) val isUserCurrentVisible = options.contains(LocationSharingOption.USER_CURRENT)