CallParticipantViewCell.h 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /**
  2. * SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors
  3. * SPDX-License-Identifier: GPL-3.0-or-later
  4. */
  5. #import <UIKit/UIKit.h>
  6. #import <WebRTC/WebRTC.h>
  7. extern NSString *const kCallParticipantCellIdentifier;
  8. extern NSString *const kCallParticipantCellNibName;
  9. extern CGFloat const kCallParticipantCellMinHeight;
  10. @class CallParticipantViewCell;
  11. @class MDCActivityIndicator;
  12. @class AvatarImageView;
  13. @class TalkActor;
  14. @protocol CallParticipantViewCellDelegate <NSObject>
  15. - (void)cellWantsToPresentScreenSharing:(CallParticipantViewCell *)participantCell;
  16. - (void)cellWantsToChangeZoom:(CallParticipantViewCell *)participantCell showOriginalSize:(BOOL)showOriginalSize;
  17. @end
  18. @interface CallParticipantViewCell : UICollectionViewCell
  19. @property (nonatomic, weak) id<CallParticipantViewCellDelegate> actionsDelegate;
  20. @property (nonatomic, strong) NSString *peerIdentifier;
  21. @property (nonatomic, strong) NSString *displayName;
  22. @property (nonatomic, assign) BOOL audioDisabled;
  23. @property (nonatomic, assign) BOOL videoDisabled;
  24. @property (nonatomic, assign) BOOL screenShared;
  25. @property (nonatomic, assign) BOOL showOriginalSize;
  26. @property (nonatomic, assign) RTCIceConnectionState connectionState;
  27. @property (nonatomic, weak) IBOutlet UIView *peerVideoView;
  28. @property (nonatomic, weak) IBOutlet UILabel *peerNameLabel;
  29. @property (nonatomic, weak) IBOutlet MDCActivityIndicator *activityIndicator;
  30. @property (nonatomic, weak) IBOutlet AvatarImageView *peerAvatarImageView;
  31. @property (nonatomic, weak) IBOutlet UIButton *audioOffIndicator;
  32. @property (nonatomic, weak) IBOutlet UIButton *screensharingIndicator;
  33. @property (nonatomic, weak) IBOutlet UIButton *raisedHandIndicator;
  34. @property (nonatomic, weak) IBOutlet NSLayoutConstraint *stackViewBottomConstraint;
  35. @property (nonatomic, weak) IBOutlet NSLayoutConstraint *stackViewLeftConstraint;
  36. @property (nonatomic, weak) IBOutlet NSLayoutConstraint *stackViewRightConstraint;
  37. @property (nonatomic, weak) IBOutlet NSLayoutConstraint *screensharingIndiciatorRightConstraint;
  38. @property (nonatomic, weak) IBOutlet NSLayoutConstraint *screensharingIndiciatorTopConstraint;
  39. - (void)setVideoView:(RTCMTLVideoView *)videoView;
  40. - (void)setSpeaking:(BOOL)speaking;
  41. - (void)setAvatarForActor:(TalkActor *)actor;
  42. - (CGSize)getRemoteVideoSize;
  43. - (void)setRemoteVideoSize:(CGSize)size;
  44. - (void)setRaiseHand:(BOOL)raised;
  45. - (void)resizeRemoteVideoView;
  46. @end