|
@@ -31,6 +31,9 @@ class ChatTitleView: UIView {
|
|
return view
|
|
return view
|
|
}()
|
|
}()
|
|
|
|
|
|
|
|
+ private let paddingNaviationButtons = 120
|
|
|
|
+ private let sizeStreamingIndicator = 28
|
|
|
|
+
|
|
init() {
|
|
init() {
|
|
super.init(frame: .zero)
|
|
super.init(frame: .zero)
|
|
setupSubviews()
|
|
setupSubviews()
|
|
@@ -47,7 +50,8 @@ class ChatTitleView: UIView {
|
|
addSubview(containerView)
|
|
addSubview(containerView)
|
|
addConstraints([ containerView.constraintAlignTopTo(self),
|
|
addConstraints([ containerView.constraintAlignTopTo(self),
|
|
containerView.constraintAlignBottomTo(self),
|
|
containerView.constraintAlignBottomTo(self),
|
|
- containerView.constraintCenterXTo(self)])
|
|
|
|
|
|
+ containerView.constraintCenterXTo(self),
|
|
|
|
+ containerView.constraintWidthTo(UIScreen.main.bounds.width - CGFloat(paddingNaviationButtons + sizeStreamingIndicator)) ])
|
|
|
|
|
|
containerView.addSubview(titleLabel)
|
|
containerView.addSubview(titleLabel)
|
|
containerView.addConstraints([ titleLabel.constraintAlignLeadingTo(containerView),
|
|
containerView.addConstraints([ titleLabel.constraintAlignLeadingTo(containerView),
|
|
@@ -73,4 +77,8 @@ class ChatTitleView: UIView {
|
|
subtitleLabel.text = subtitle
|
|
subtitleLabel.text = subtitle
|
|
locationStreamingIndicator.isHidden = !isLocationStreaming
|
|
locationStreamingIndicator.isHidden = !isLocationStreaming
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ func hideLocationStreamingIndicator() {
|
|
|
|
+ locationStreamingIndicator.isHidden = true
|
|
|
|
+ }
|
|
}
|
|
}
|