TIMAdapter.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. //
  2. // TIMAdapter.h
  3. // TIMAdapter
  4. //
  5. // Created by AlexiChen on 16/1/29.
  6. // Copyright © 2016年 AlexiChen. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. #import <QALSDK/QalSDKProxy.h>
  10. #import <ImSDK/ImSDK.h>
  11. #import <TLSSDK/TLSHelper.h>
  12. #define kSupportCustomConversation 1
  13. typedef NS_ENUM(NSInteger, IMAConType)
  14. {
  15. IMA_Unknow, // 未知
  16. IMA_C2C = TIM_C2C, // C2C类型
  17. IMA_Group = TIM_GROUP, // 群聊类型
  18. IMA_System = TIM_SYSTEM, // 系统消息
  19. // 定制会话类型
  20. IMA_Connect, // 网络联接
  21. // kSupportCustomConversation 为 1时有效
  22. IMA_Sys_NewFriend, // 新朋友系统消息
  23. IMA_Sys_GroupTip, // 群系统消息通知
  24. };
  25. #define kGetConverSationList 0
  26. #define kSupportCustomConversation 1
  27. //==============================
  28. // 聊天图片缩约图最大高度
  29. #define kChatPicThumbMaxHeight 190.f
  30. // 聊天图片缩约图最大宽度
  31. #define kChatPicThumbMaxWidth 66.f
  32. //==============================
  33. #define kSaftyWordsCode 80001
  34. // IMAMsg扩展参数的键
  35. #define kIMAMSG_Image_ThumbWidth @"kIMA_ThumbWidth"
  36. #define kIMAMSG_Image_ThumbHeight @"kIMA_ThumbHeight"
  37. #define kIMAMSG_Image_OrignalPath @"kIMA_OrignalPath"
  38. #define kIMAMSG_Image_ThumbPath @"kIMA_ThumbPath"
  39. //==============================
  40. #define IMALocalizedError(intCode, enStr) NSLocalizedString(([NSString stringWithFormat:@"%d", (int)intCode]), enStr)
  41. // 演求个人资料里面的如何增加扩展字段
  42. #if kIsTCShowSupportIMCustom
  43. #define kIMCustomFlag @"Tag_Profile_Custom_1400009129_Param"
  44. #endif
  45. // IMA中用到的消息相关通知
  46. #define kIMAMSG_RevokeNotification @"kIMAMSG_RevokeNotification"
  47. #define kIMAMSG_DeleteNotification @"kIMAMSG_DeleteNotification"
  48. #define kIMAMSG_ResendNotification @"kIMAMSG_ResendNotification"
  49. #define kIMAMSG_ChangedNotification @"kIMAMSG_ChangedNotification"
  50. #define kSaftyWordsCode 80001
  51. #import "IMAShow.h"
  52. #import "IMAModel.h"
  53. #import "IMAPlatformHeaders.h"