Resolve more errors
This commit is contained in:
parent
11dff385cc
commit
ebff1f7ff3
|
@ -235,7 +235,7 @@ class CallHeader: UIView {
|
|||
"GROUP_CALL_MANY_PEOPLE_HERE_FORMAT",
|
||||
comment: "Text explaining that there are more than three people in the group call. Embeds {{ %1$@ participant1, %2$@ participant2, %3$@ participantCount-2 }}"
|
||||
)
|
||||
callTitleText = String(format: formatString, memberNames[0], memberNames[1], OWSFormat.formatInt(memberNames.count - 2))
|
||||
callTitleText = String(format: formatString, memberNames[0], memberNames[1], OWSFormat.formatInt(Int32(memberNames.count) - 2))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -311,10 +311,10 @@ private class GroupMembersButton: UIButton {
|
|||
autoSetDimension(.height, toSize: 40)
|
||||
|
||||
iconImageView.contentMode = .scaleAspectFit
|
||||
iconImageView.setTemplateImage(#imageLiteral(resourceName: "group-solid-24"), tintColor: .ows_white)
|
||||
iconImageView.setTemplateImage(#imageLiteral(resourceName: "group-solid-24"), tintColor: .white)
|
||||
addSubview(iconImageView)
|
||||
iconImageView.autoPinEdge(toSuperviewEdge: .leading)
|
||||
iconImageView.autoSetDimensions(to: CGSize(square: 22))
|
||||
iconImageView.autoSetDimensions(to: CGSize(width: 22, height: 22))
|
||||
iconImageView.autoPinEdge(toSuperviewEdge: .top, withInset: 2)
|
||||
|
||||
countLabel.font = .systemFont(ofSize: Values.mediumFontSize)
|
||||
|
|
|
@ -164,12 +164,12 @@ private class BannerView: UIView {
|
|||
clipsToBounds = true
|
||||
|
||||
if UIAccessibility.isReduceTransparencyEnabled {
|
||||
backgroundColor = .ows_blackAlpha80
|
||||
backgroundColor = .black.withAlphaComponent(0.8)
|
||||
} else {
|
||||
let blurEffectView = UIVisualEffectView(effect: UIBlurEffect(style: .dark))
|
||||
addSubview(blurEffectView)
|
||||
blurEffectView.autoPinEdgesToSuperviewEdges()
|
||||
backgroundColor = .ows_blackAlpha40
|
||||
backgroundColor = .black.withAlphaComponent(0.4)
|
||||
}
|
||||
|
||||
let displayNames = databaseStorage.read { transaction in
|
||||
|
|
|
@ -30,7 +30,6 @@ final class ConversationVC : BaseVC, ConversationViewModelDelegate, OWSConversat
|
|||
var scrollDistanceToBottomBeforeUpdate: CGFloat?
|
||||
var baselineKeyboardHeight: CGFloat = 0
|
||||
|
||||
var audioSession: OWSAudioSession { Environment.shared.audioSession }
|
||||
var dbConnection: YapDatabaseConnection { OWSPrimaryStorage.shared().uiDatabaseConnection }
|
||||
var viewItems: [ConversationViewItem] { viewModel.viewState.viewItems }
|
||||
override var canBecomeFirstResponder: Bool { true }
|
||||
|
|
|
@ -9,6 +9,14 @@ import Foundation
|
|||
@objc
|
||||
public extension NSObject {
|
||||
|
||||
final var audioSession: OWSAudioSession {
|
||||
Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
static var audioSession: OWSAudioSession {
|
||||
Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
final var individualCallUIAdapter: CallUIAdapter {
|
||||
AppEnvironment.shared.callServiceRef.individualCallService.callUIAdapter
|
||||
}
|
||||
|
@ -37,6 +45,14 @@ public extension NSObject {
|
|||
public protocol Dependencies { }
|
||||
|
||||
public extension Dependencies {
|
||||
|
||||
var audioSession: OWSAudioSession {
|
||||
Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
static var audioSession: OWSAudioSession {
|
||||
Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
var individualCallUIAdapter: CallUIAdapter {
|
||||
AppEnvironment.shared.callServiceRef.individualCallService.callUIAdapter
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
sounds:(OWSSounds *)sounds
|
||||
windowManager:(OWSWindowManager *)windowManager;
|
||||
|
||||
@property (nonatomic, readonly) OWSAudioSession *audioSession;
|
||||
@property (nonatomic, readonly) OWSAudioSession *audioSessionRef;
|
||||
@property (nonatomic, readonly) id<OWSProximityMonitoringManager> proximityMonitoringManager;
|
||||
@property (nonatomic, readonly) OWSPreferences *preferences;
|
||||
@property (nonatomic, readonly) OWSSounds *sounds;
|
||||
|
|
|
@ -9,7 +9,7 @@ static Environment *sharedEnvironment = nil;
|
|||
|
||||
@interface Environment ()
|
||||
|
||||
@property (nonatomic) OWSAudioSession *audioSession;
|
||||
@property (nonatomic) OWSAudioSession *audioSessionRef;
|
||||
@property (nonatomic) OWSPreferences *preferences;
|
||||
@property (nonatomic) id<OWSProximityMonitoringManager> proximityMonitoringManager;
|
||||
@property (nonatomic) OWSSounds *sounds;
|
||||
|
@ -53,7 +53,7 @@ static Environment *sharedEnvironment = nil;
|
|||
return self;
|
||||
}
|
||||
|
||||
_audioSession = audioSession;
|
||||
_audioSessionRef = audioSession;
|
||||
_preferences = preferences;
|
||||
_proximityMonitoringManager = proximityMonitoringManager;
|
||||
_sounds = sounds;
|
||||
|
|
|
@ -95,7 +95,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
- (OWSAudioSession *)audioSession
|
||||
{
|
||||
return Environment.shared.audioSession;
|
||||
return Environment.shared.audioSessionRef;
|
||||
}
|
||||
|
||||
#pragma mark
|
||||
|
|
|
@ -24,7 +24,7 @@ public class AudioActivity: NSObject {
|
|||
// MARK: Dependencies
|
||||
|
||||
var audioSession: OWSAudioSession {
|
||||
return Environment.shared.audioSession
|
||||
return Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
// MARK:
|
||||
|
|
|
@ -35,7 +35,7 @@ public class OWSVideoPlayer: NSObject {
|
|||
// MARK: Dependencies
|
||||
|
||||
var audioSession: OWSAudioSession {
|
||||
return Environment.shared.audioSession
|
||||
return Environment.shared.audioSessionRef
|
||||
}
|
||||
|
||||
// MARK: Playback Controls
|
||||
|
|
Loading…
Reference in New Issue