EaseBubbleView.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. /************************************************************
  2. * * Hyphenate CONFIDENTIAL
  3. * __________________
  4. * Copyright (C) 2016 Hyphenate Inc. All rights reserved.
  5. *
  6. * NOTICE: All information contained herein is, and remains
  7. * the property of Hyphenate Inc.
  8. * Dissemination of this information or reproduction of this material
  9. * is strictly forbidden unless prior written permission is obtained
  10. * from Hyphenate Inc.
  11. */
  12. #import <UIKit/UIKit.h>
  13. extern CGFloat const EaseMessageCellPadding;
  14. extern NSString *const EaseMessageCellIdentifierSendText;
  15. extern NSString *const EaseMessageCellIdentifierSendLocation;
  16. extern NSString *const EaseMessageCellIdentifierSendVoice;
  17. extern NSString *const EaseMessageCellIdentifierSendVideo;
  18. extern NSString *const EaseMessageCellIdentifierSendImage;
  19. extern NSString *const EaseMessageCellIdentifierSendFile;
  20. extern NSString *const EaseMessageCellIdentifierRecvText;
  21. extern NSString *const EaseMessageCellIdentifierRecvLocation;
  22. extern NSString *const EaseMessageCellIdentifierRecvVoice;
  23. extern NSString *const EaseMessageCellIdentifierRecvVideo;
  24. extern NSString *const EaseMessageCellIdentifierRecvImage;
  25. extern NSString *const EaseMessageCellIdentifierRecvFile;
  26. @interface EaseBubbleView : UIView
  27. {
  28. UIEdgeInsets _margin;
  29. CGFloat _fileIconSize;
  30. }
  31. @property (nonatomic) BOOL isSender;
  32. @property (nonatomic, readonly) UIEdgeInsets margin;
  33. @property (strong, nonatomic) NSMutableArray *marginConstraints;
  34. @property (strong, nonatomic) UIImageView *backgroundImageView;
  35. //text views
  36. @property (strong, nonatomic) UILabel *textLabel;
  37. //image views
  38. @property (strong, nonatomic) UIImageView *imageView;
  39. //location views
  40. @property (strong, nonatomic) UIImageView *locationImageView;
  41. @property (strong, nonatomic) UILabel *locationLabel;
  42. //voice views
  43. @property (strong, nonatomic) UIImageView *voiceImageView;
  44. @property (strong, nonatomic) UILabel *voiceDurationLabel;
  45. @property (strong, nonatomic) UIImageView *isReadView;
  46. //video views
  47. @property (strong, nonatomic) UIImageView *videoImageView;
  48. @property (strong, nonatomic) UIImageView *videoTagView;
  49. //file views
  50. @property (strong, nonatomic) UIImageView *fileIconView;
  51. @property (strong, nonatomic) UILabel *fileNameLabel;
  52. @property (strong, nonatomic) UILabel *fileSizeLabel;
  53. - (instancetype)initWithMargin:(UIEdgeInsets)margin
  54. isSender:(BOOL)isSender;
  55. @end