mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-04 10:32:34 +00:00
Implement Notification Settings
- Add UI and logic to inform the user of mismatched notification settings and help them correct it. - Display a warning when the system notification settings are disabled and a link out to the app settings. - A toggle to disable notifications for the device - A screen for editing the group and direct chat notification defaults. - A toggle for switching on/off atRoom and call notifications.
This commit is contained in:
+1
-1
@@ -106,7 +106,7 @@ class RoomDetailsPresenter @Inject constructor(
|
||||
}
|
||||
RoomDetailsEvent.UnmuteNotification -> {
|
||||
scope.launch(dispatchers.io) {
|
||||
client.notificationSettingsService().unmuteRoom(room.roomId, room.isEncrypted, room.activeMemberCount)
|
||||
client.notificationSettingsService().unmuteRoom(room.roomId, room.isEncrypted, room.isOneToOne)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-3
@@ -75,8 +75,6 @@ class RoomNotificationSettingsPresenter @Inject constructor(
|
||||
}
|
||||
}
|
||||
|
||||
Timber.d("NotifState: $roomNotificationSettingsState")
|
||||
|
||||
return RoomNotificationSettingsState(
|
||||
roomNotificationSettings = roomNotificationSettingsState.roomNotificationSettings(),
|
||||
defaultRoomNotificationMode = defaultRoomNotificationMode.value,
|
||||
@@ -97,7 +95,7 @@ class RoomNotificationSettingsPresenter @Inject constructor(
|
||||
private fun CoroutineScope.getDefaultRoomNotificationMode(defaultRoomNotificationMode: MutableState<RoomNotificationMode?>) = launch {
|
||||
defaultRoomNotificationMode.value = notificationSettingsService.getDefaultRoomNotificationMode(
|
||||
room.isEncrypted,
|
||||
room.activeMemberCount
|
||||
room.isOneToOne
|
||||
).getOrThrow()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user