mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Add a RoomScreenHook.
This commit is contained in:
@@ -9,6 +9,10 @@ import Foundation
|
||||
|
||||
class AppHooks: AppHooksProtocol {
|
||||
#if IS_MAIN_APP
|
||||
func configure(with userSession: UserSessionProtocol?) async {
|
||||
await roomScreenHook.configure(with: userSession)
|
||||
}
|
||||
|
||||
private(set) var appSettingsHook: AppSettingsHookProtocol = DefaultAppSettingsHook()
|
||||
func registerAppSettingsHook(_ hook: AppSettingsHookProtocol) {
|
||||
appSettingsHook = hook
|
||||
@@ -28,6 +32,11 @@ class AppHooks: AppHooksProtocol {
|
||||
func registerCertificateValidatorHook(_ hook: CertificateValidatorHookProtocol) {
|
||||
certificateValidatorHook = hook
|
||||
}
|
||||
|
||||
private(set) var roomScreenHook: RoomScreenHookProtocol = DefaultRoomScreenHook()
|
||||
func registerRoomScreenHook(_ hook: RoomScreenHookProtocol) {
|
||||
roomScreenHook = hook
|
||||
}
|
||||
#endif
|
||||
|
||||
private(set) var clientBuilderHook: ClientBuilderHookProtocol = DefaultClientBuilderHook()
|
||||
@@ -38,6 +47,10 @@ class AppHooks: AppHooksProtocol {
|
||||
|
||||
protocol AppHooksProtocol {
|
||||
func setUp()
|
||||
|
||||
#if IS_MAIN_APP
|
||||
func configure(with userSession: UserSessionProtocol?) async
|
||||
#endif
|
||||
}
|
||||
|
||||
extension AppHooksProtocol {
|
||||
|
||||
Reference in New Issue
Block a user