rename CallNotificationsAdapter->NotificationsAdapter

pull/1/head
Michael Kirk 6 years ago
parent 18df5e43e9
commit ac3bbe26ba

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -7,8 +7,8 @@ import Foundation
/** /**
* Present call related notifications to the user. * Present call related notifications to the user.
*/ */
@objc(OWSCallNotificationsAdapter) @objc(OWSNotificationsAdapter)
public class CallNotificationsAdapter: NSObject { public class NotificationsAdapter: NSObject {
var adaptee: OWSCallNotificationsAdaptee { var adaptee: OWSCallNotificationsAdaptee {
// TODO: We may eventually want to use UserNotificationsAdaptee instead. // TODO: We may eventually want to use UserNotificationsAdaptee instead.

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -13,8 +13,8 @@ class DebugUINotifications: DebugUIPage {
var notificationsManager: NotificationsManager { var notificationsManager: NotificationsManager {
return AppEnvironment.shared.notificationsManager return AppEnvironment.shared.notificationsManager
} }
var notificationsAdapter: CallNotificationsAdapter { var notificationsAdapter: NotificationsAdapter {
return AppEnvironment.shared.callNotificationsAdapter return AppEnvironment.shared.NotificationsAdapter
} }
var messageSender: MessageSender { var messageSender: MessageSender {
return SSKEnvironment.shared.messageSender return SSKEnvironment.shared.messageSender

@ -401,8 +401,8 @@ private class SignalCallData: NSObject {
return AppEnvironment.shared.accountManager return AppEnvironment.shared.accountManager
} }
private var notificationsAdapter: CallNotificationsAdapter { private var notificationsAdapter: NotificationsAdapter {
return AppEnvironment.shared.callNotificationsAdapter return AppEnvironment.shared.NotificationsAdapter
} }
// MARK: - Notifications // MARK: - Notifications

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -11,13 +11,13 @@ import SignalMessaging
*/ */
class NonCallKitCallUIAdaptee: NSObject, CallUIAdaptee { class NonCallKitCallUIAdaptee: NSObject, CallUIAdaptee {
let notificationsAdapter: CallNotificationsAdapter let notificationsAdapter: NotificationsAdapter
let callService: CallService let callService: CallService
// Starting/Stopping incoming call ringing is our apps responsibility for the non CallKit interface. // Starting/Stopping incoming call ringing is our apps responsibility for the non CallKit interface.
let hasManualRinger = true let hasManualRinger = true
required init(callService: CallService, notificationsAdapter: CallNotificationsAdapter) { required init(callService: CallService, notificationsAdapter: NotificationsAdapter) {
AssertIsOnMainThread() AssertIsOnMainThread()
self.callService = callService self.callService = callService

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -20,7 +20,7 @@ final class CallKitCallUIAdaptee: NSObject, CallUIAdaptee, CXProviderDelegate {
private let callManager: CallKitCallManager private let callManager: CallKitCallManager
internal let callService: CallService internal let callService: CallService
internal let notificationsAdapter: CallNotificationsAdapter internal let notificationsAdapter: NotificationsAdapter
internal let contactsManager: OWSContactsManager internal let contactsManager: OWSContactsManager
private let showNamesOnCallScreen: Bool private let showNamesOnCallScreen: Bool
private let provider: CXProvider private let provider: CXProvider
@ -76,7 +76,7 @@ final class CallKitCallUIAdaptee: NSObject, CallUIAdaptee, CXProviderDelegate {
return providerConfiguration return providerConfiguration
} }
init(callService: CallService, contactsManager: OWSContactsManager, notificationsAdapter: CallNotificationsAdapter, showNamesOnCallScreen: Bool, useSystemCallLog: Bool) { init(callService: CallService, contactsManager: OWSContactsManager, notificationsAdapter: NotificationsAdapter, showNamesOnCallScreen: Bool, useSystemCallLog: Bool) {
AssertIsOnMainThread() AssertIsOnMainThread()
Logger.debug("") Logger.debug("")

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -10,7 +10,7 @@ import SignalMessaging
import WebRTC import WebRTC
protocol CallUIAdaptee { protocol CallUIAdaptee {
var notificationsAdapter: CallNotificationsAdapter { get } var notificationsAdapter: NotificationsAdapter { get }
var callService: CallService { get } var callService: CallService { get }
var hasManualRinger: Bool { get } var hasManualRinger: Bool { get }
@ -88,7 +88,7 @@ extension CallUIAdaptee {
internal let audioService: CallAudioService internal let audioService: CallAudioService
internal let callService: CallService internal let callService: CallService
public required init(callService: CallService, contactsManager: OWSContactsManager, notificationsAdapter: CallNotificationsAdapter) { public required init(callService: CallService, contactsManager: OWSContactsManager, notificationsAdapter: NotificationsAdapter) {
AssertIsOnMainThread() AssertIsOnMainThread()
self.contactsManager = contactsManager self.contactsManager = contactsManager

@ -1,5 +1,5 @@
// //
// Copyright (c) 2018 Open Whisper Systems. All rights reserved. // Copyright (c) 2019 Open Whisper Systems. All rights reserved.
// //
import Foundation import Foundation
@ -44,7 +44,7 @@ import SignalMessaging
public var accountManager: AccountManager public var accountManager: AccountManager
@objc @objc
public var callNotificationsAdapter: CallNotificationsAdapter public var NotificationsAdapter: NotificationsAdapter
@objc @objc
public var pushRegistrationManager: PushRegistrationManager public var pushRegistrationManager: PushRegistrationManager
@ -68,7 +68,7 @@ import SignalMessaging
self.messageFetcherJob = MessageFetcherJob() self.messageFetcherJob = MessageFetcherJob()
self.notificationsManager = NotificationsManager() self.notificationsManager = NotificationsManager()
self.accountManager = AccountManager() self.accountManager = AccountManager()
self.callNotificationsAdapter = CallNotificationsAdapter() self.notificationsAdapter = NotificationsAdapter()
self.pushRegistrationManager = PushRegistrationManager() self.pushRegistrationManager = PushRegistrationManager()
self.pushManager = PushManager() self.pushManager = PushManager()
self.sessionResetJobQueue = SessionResetJobQueue() self.sessionResetJobQueue = SessionResetJobQueue()

Loading…
Cancel
Save