mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-26 19:34:25 +02:00
Timeline: Rename call cells.
This commit is contained in:
@@ -3260,14 +3260,14 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
|
||||
[self showReactionHistoryForEventId:tappedEventId animated:YES];
|
||||
}
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusBubbleCell.callBackAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusCell.callBackAction])
|
||||
{
|
||||
MXEvent *callInviteEvent = userInfo[kMXKRoomBubbleCellEventKey];
|
||||
MXCallInviteEventContent *eventContent = [MXCallInviteEventContent modelFromJSON:callInviteEvent.content];
|
||||
|
||||
[self placeCallWithVideo2:eventContent.isVideoCall];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusBubbleCell.declineAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusCell.declineAction])
|
||||
{
|
||||
MXEvent *callInviteEvent = userInfo[kMXKRoomBubbleCellEventKey];
|
||||
MXCallInviteEventContent *eventContent = [MXCallInviteEventContent modelFromJSON:callInviteEvent.content];
|
||||
@@ -3275,7 +3275,7 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
|
||||
MXCall *call = [self.mainSession.callManager callWithCallId:eventContent.callId];
|
||||
[call hangup];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusBubbleCell.answerAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusCell.answerAction])
|
||||
{
|
||||
MXEvent *callInviteEvent = userInfo[kMXKRoomBubbleCellEventKey];
|
||||
MXCallInviteEventContent *eventContent = [MXCallInviteEventContent modelFromJSON:callInviteEvent.content];
|
||||
@@ -3283,7 +3283,7 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
|
||||
MXCall *call = [self.mainSession.callManager callWithCallId:eventContent.callId];
|
||||
[call answer];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusBubbleCell.endCallAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomDirectCallStatusCell.endCallAction])
|
||||
{
|
||||
MXEvent *callInviteEvent = userInfo[kMXKRoomBubbleCellEventKey];
|
||||
MXCallInviteEventContent *eventContent = [MXCallInviteEventContent modelFromJSON:callInviteEvent.content];
|
||||
@@ -3291,8 +3291,8 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
|
||||
MXCall *call = [self.mainSession.callManager callWithCallId:eventContent.callId];
|
||||
[call hangup];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusBubbleCell.joinAction] ||
|
||||
[actionIdentifier isEqualToString:RoomGroupCallStatusBubbleCell.answerAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusCell.joinAction] ||
|
||||
[actionIdentifier isEqualToString:RoomGroupCallStatusCell.answerAction])
|
||||
{
|
||||
MXWeakify(self);
|
||||
|
||||
@@ -3323,12 +3323,12 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
|
||||
inMatrixSession:customizedRoomDataSource.mxSession];
|
||||
[[JitsiService shared] resetDeclineForWidgetWithId:widget.widgetId];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusBubbleCell.leaveAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusCell.leaveAction])
|
||||
{
|
||||
[self endActiveJitsiCall];
|
||||
[self reloadBubblesTable:YES];
|
||||
}
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusBubbleCell.declineAction])
|
||||
else if ([actionIdentifier isEqualToString:RoomGroupCallStatusCell.declineAction])
|
||||
{
|
||||
MXEvent *widgetEvent = userInfo[kMXKRoomBubbleCellEventKey];
|
||||
Widget *widget = [[Widget alloc] initWithWidgetEvent:widgetEvent
|
||||
|
||||
+4
-4
@@ -17,7 +17,7 @@
|
||||
import UIKit
|
||||
import Reusable
|
||||
|
||||
class CallBubbleCellBaseContentView: UIView {
|
||||
class CallCellContentView: UIView {
|
||||
|
||||
private enum Constants {
|
||||
static let callSummaryWithBottomViewHeight: CGFloat = 20
|
||||
@@ -88,11 +88,11 @@ class CallBubbleCellBaseContentView: UIView {
|
||||
|
||||
}
|
||||
|
||||
extension CallBubbleCellBaseContentView: NibLoadable {
|
||||
extension CallCellContentView: NibLoadable {
|
||||
|
||||
}
|
||||
|
||||
extension CallBubbleCellBaseContentView: Themable {
|
||||
extension CallCellContentView: Themable {
|
||||
|
||||
func update(theme: Theme) {
|
||||
self.theme = theme
|
||||
@@ -114,7 +114,7 @@ extension CallBubbleCellBaseContentView: Themable {
|
||||
|
||||
// MARK: - RoomCellReadReceiptsDisplayable
|
||||
|
||||
extension CallBubbleCellBaseContentView: RoomCellReadReceiptsDisplayable {
|
||||
extension CallCellContentView: RoomCellReadReceiptsDisplayable {
|
||||
|
||||
func addReadReceiptsView(_ readReceiptsView: UIView) {
|
||||
self.readReceiptsContentView.vc_removeAllSubviews()
|
||||
+3
-3
@@ -1,15 +1,15 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="18122" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="19529" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="retina6_1" orientation="portrait" appearance="light"/>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="18093"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="19519"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="iN0-l3-epB" customClass="CallBubbleCellBaseContentView" customModule="Riot" customModuleProvider="target">
|
||||
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="iN0-l3-epB" customClass="CallCellContentView" customModule="Riot" customModuleProvider="target">
|
||||
<rect key="frame" x="0.0" y="0.0" width="414" height="220"/>
|
||||
<subviews>
|
||||
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="6" translatesAutoresizingMaskIntoConstraints="NO" id="pdr-Jo-LHQ">
|
||||
+2
-2
@@ -20,7 +20,7 @@ import UIKit
|
||||
private let MSEC_PER_SEC: TimeInterval = 1000
|
||||
|
||||
@objcMembers
|
||||
class RoomDirectCallStatusBubbleCell: RoomBaseCallBubbleCell {
|
||||
class RoomDirectCallStatusCell: RoomCallBaseCell {
|
||||
|
||||
private static var className: String {
|
||||
return String(describing: self)
|
||||
@@ -446,7 +446,7 @@ class RoomDirectCallStatusBubbleCell: RoomBaseCallBubbleCell {
|
||||
return ""
|
||||
}
|
||||
|
||||
return RoomDirectCallStatusBubbleCell.callDurationFormatter.string(from: duration) ?? ""
|
||||
return RoomDirectCallStatusCell.callDurationFormatter.string(from: duration) ?? ""
|
||||
}
|
||||
|
||||
}
|
||||
+2
-2
@@ -20,7 +20,7 @@ import UIKit
|
||||
private let MSEC_PER_SEC: TimeInterval = 1000
|
||||
|
||||
@objcMembers
|
||||
class RoomGroupCallStatusBubbleCell: RoomBaseCallBubbleCell {
|
||||
class RoomGroupCallStatusCell: RoomCallBaseCell {
|
||||
|
||||
private static var className: String {
|
||||
return String(describing: self)
|
||||
@@ -335,7 +335,7 @@ class RoomGroupCallStatusBubbleCell: RoomBaseCallBubbleCell {
|
||||
return ""
|
||||
}
|
||||
|
||||
return RoomGroupCallStatusBubbleCell.callDurationFormatter.string(from: duration) ?? ""
|
||||
return RoomGroupCallStatusCell.callDurationFormatter.string(from: duration) ?? ""
|
||||
}
|
||||
|
||||
}
|
||||
+7
-7
@@ -17,10 +17,10 @@
|
||||
import UIKit
|
||||
import Reusable
|
||||
|
||||
class RoomBaseCallBubbleCell: MXKRoomBubbleTableViewCell {
|
||||
class RoomCallBaseCell: MXKRoomBubbleTableViewCell {
|
||||
|
||||
lazy var innerContentView: CallBubbleCellBaseContentView = {
|
||||
return CallBubbleCellBaseContentView.loadFromNib()
|
||||
lazy var innerContentView: CallCellContentView = {
|
||||
return CallCellContentView.loadFromNib()
|
||||
}()
|
||||
|
||||
override required init!(style: UITableViewCell.CellStyle, reuseIdentifier: String!) {
|
||||
@@ -65,7 +65,7 @@ class RoomBaseCallBubbleCell: MXKRoomBubbleTableViewCell {
|
||||
innerContentView.bottomContainerView.vc_addSubViewMatchingParent(bottomContentView)
|
||||
}
|
||||
|
||||
class func createSizingView() -> RoomBaseCallBubbleCell {
|
||||
class func createSizingView() -> RoomCallBaseCell {
|
||||
return self.init(style: .default, reuseIdentifier: self.defaultReuseIdentifier())
|
||||
}
|
||||
|
||||
@@ -144,7 +144,7 @@ class RoomBaseCallBubbleCell: MXKRoomBubbleTableViewCell {
|
||||
|
||||
}
|
||||
|
||||
extension RoomBaseCallBubbleCell: RoomCellReadReceiptsDisplayable {
|
||||
extension RoomCallBaseCell: RoomCellReadReceiptsDisplayable {
|
||||
|
||||
func addReadReceiptsView(_ readReceiptsView: UIView) {
|
||||
innerContentView.addReadReceiptsView(readReceiptsView)
|
||||
@@ -156,7 +156,7 @@ extension RoomBaseCallBubbleCell: RoomCellReadReceiptsDisplayable {
|
||||
|
||||
}
|
||||
|
||||
extension RoomBaseCallBubbleCell: Themable {
|
||||
extension RoomCallBaseCell: Themable {
|
||||
|
||||
func update(theme: Theme) {
|
||||
innerContentView.update(theme: theme)
|
||||
@@ -167,6 +167,6 @@ extension RoomBaseCallBubbleCell: Themable {
|
||||
|
||||
}
|
||||
|
||||
extension RoomBaseCallBubbleCell: NibReusable {
|
||||
extension RoomCallBaseCell: NibReusable {
|
||||
|
||||
}
|
||||
+3
-3
@@ -1,16 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="19529" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
|
||||
<device id="retina6_1" orientation="portrait" appearance="light"/>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17703"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="19519"/>
|
||||
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" translatesAutoresizingMaskIntoConstraints="NO" id="KGk-i7-Jjw" customClass="RoomBaseCallBubbleCell" customModule="Riot" customModuleProvider="target">
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" translatesAutoresizingMaskIntoConstraints="NO" id="KGk-i7-Jjw" customClass="RoomCallBaseCell" customModule="Riot" customModuleProvider="target">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="160"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" translatesAutoresizingMaskIntoConstraints="NO" id="H2p-sc-9uM">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="160"/>
|
||||
@@ -236,8 +236,8 @@
|
||||
|
||||
- (void)registerCallCellsForTableView:(UITableView*)tableView
|
||||
{
|
||||
[tableView registerClass:RoomDirectCallStatusBubbleCell.class forCellReuseIdentifier:RoomDirectCallStatusBubbleCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:RoomGroupCallStatusBubbleCell.class forCellReuseIdentifier:RoomGroupCallStatusBubbleCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:RoomDirectCallStatusCell.class forCellReuseIdentifier:RoomDirectCallStatusCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:RoomGroupCallStatusCell.class forCellReuseIdentifier:RoomGroupCallStatusCell.defaultReuseIdentifier];
|
||||
}
|
||||
|
||||
- (void)registerVoiceMessageCellsForTableView:(UITableView*)tableView
|
||||
@@ -494,8 +494,8 @@
|
||||
- (NSDictionary<NSNumber*, Class>*)callCellsMapping
|
||||
{
|
||||
return @{
|
||||
@(RoomTimelineCellIdentifierDirectCallStatus) : RoomDirectCallStatusBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierGroupCallStatus) : RoomGroupCallStatusBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierDirectCallStatus) : RoomDirectCallStatusCell.class,
|
||||
@(RoomTimelineCellIdentifierGroupCallStatus) : RoomGroupCallStatusCell.class,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user