Fix small issue on the settings.
This commit is contained in:
parent
33911c880c
commit
b1e062a204
|
@ -101,7 +101,11 @@ class VectorSettingsNotificationPreferenceFragment @Inject constructor(
|
|||
findPreference<SwitchPreference>(VectorPreferences.SETTINGS_ENABLE_THIS_DEVICE_PREFERENCE_KEY)?.let {
|
||||
it.setTransactionalSwitchChangeListener(lifecycleScope) { isChecked ->
|
||||
if (isChecked) {
|
||||
unifiedPushHelper.register(requireActivity())
|
||||
unifiedPushHelper.register(requireActivity()) {
|
||||
// Update the summary
|
||||
findPreference<VectorPreference>(VectorPreferences.SETTINGS_UNIFIED_PUSH_RE_REGISTER_KEY)
|
||||
?.summary = unifiedPushHelper.getCurrentDistributorName()
|
||||
}
|
||||
} else {
|
||||
unifiedPushHelper.unregister(pushersManager)
|
||||
session.pushersService().refreshPushers()
|
||||
|
|
|
@ -52,8 +52,9 @@
|
|||
android:title="@string/settings_notification_configuration">
|
||||
|
||||
<im.vector.app.core.preference.VectorPreference
|
||||
android:persistent="false"
|
||||
android:dependency="SETTINGS_ENABLE_THIS_DEVICE_PREFERENCE_KEY"
|
||||
android:key="SETTINGS_UNIFIED_PUSH_RE_REGISTER_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_unifiedpush_reregister" />
|
||||
|
||||
<!-- For API < 26 -->
|
||||
|
|
Loading…
Reference in New Issue