EMMessageCell.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. //
  2. // EMMessageCell.h
  3. // ChatDemo-UI3.0
  4. //
  5. // Created by XieYajie on 2019/1/25.
  6. // Copyright © 2019 XieYajie. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. #import "EMMessageModel.h"
  10. #import "EMMessageBubbleView.h"
  11. NS_ASSUME_NONNULL_BEGIN
  12. @protocol EMMessageCellDelegate;
  13. @interface EMMessageCell : UITableViewCell
  14. @property (nonatomic, weak) id<EMMessageCellDelegate> delegate;
  15. @property (nonatomic, strong, readonly) EMMessageBubbleView *bubbleView;
  16. @property (nonatomic) EMMessageDirection direction;
  17. @property (nonatomic, strong) EMMessageModel *model;
  18. @property (nonatomic, copy) NSString *IconUrl;
  19. @property (nonatomic, copy) NSString *name;
  20. + (NSString *)cellIdentifierWithDirection:(EMMessageDirection)aDirection
  21. type:(EMMessageType)aType;
  22. - (instancetype)initWithDirection:(EMMessageDirection)aDirection
  23. type:(EMMessageType)aType;
  24. @end
  25. @protocol EMMessageCellDelegate <NSObject>
  26. @optional
  27. - (void)messageCellDidSelected:(EMMessageCell *)aCell;
  28. - (void)messageCellDidLongPress:(EMMessageCell *)aCell;
  29. - (void)messageCellDidResend:(EMMessageModel *)aModel;
  30. - (void)messageReadReceiptDetil:(EMMessageCell *)aCell;
  31. - (void)messageClickUserIcon:(EMMessageCell *)aCell;
  32. @end
  33. NS_ASSUME_NONNULL_END