Update SDK to 1.2.8
This commit is contained in:
parent
27293375a4
commit
6527295f1f
@ -1,6 +1,6 @@
|
||||
## 1.0.5
|
||||
|
||||
Upgrade sdk to 1.2.1
|
||||
Upgrade sdk to 1.2.8
|
||||
|
||||
## 1.0.4
|
||||
|
||||
|
@ -51,5 +51,5 @@ android {
|
||||
}
|
||||
}
|
||||
dependencies {
|
||||
implementation 'io.openim:client-sdk:1.2.1@aar'
|
||||
implementation 'io.openim:client-sdk:1.2.8@aar'
|
||||
}
|
@ -19,6 +19,11 @@ public class MessageManager extends BaseManager {
|
||||
private static boolean initializedListener = false;
|
||||
private final static Map<String, AdvancedMsgListener> listeners = new ConcurrentHashMap<>();
|
||||
|
||||
// protected void clearListeners() {
|
||||
// initializedListener = false;
|
||||
// listeners.clear();
|
||||
// }
|
||||
|
||||
private final static OnAdvancedMsgListener sdkMsgListener = new OnAdvancedMsgListener() {
|
||||
@Override
|
||||
public void onRecvC2CReadReceipt(String s) {
|
||||
@ -44,20 +49,21 @@ public class MessageManager extends BaseManager {
|
||||
|
||||
public void addAdvancedMsgListener(MethodCall methodCall, MethodChannel.Result result) {
|
||||
String key = methodCall.argument(KEY_ID);
|
||||
listeners.put(key, new AdvancedMsgListener(key));
|
||||
if (!initializedListener) {
|
||||
initializedListener = true;
|
||||
Open_im_sdk.addAdvancedMsgListener(sdkMsgListener);
|
||||
}
|
||||
Open_im_sdk.addAdvancedMsgListener(new AdvancedMsgListener(key));
|
||||
// listeners.put(key, new AdvancedMsgListener(key));
|
||||
// if (!initializedListener) {
|
||||
// initializedListener = true;
|
||||
// Open_im_sdk.addAdvancedMsgListener(sdkMsgListener);
|
||||
// }
|
||||
}
|
||||
|
||||
public void removeAdvancedMsgListener(MethodCall methodCall, MethodChannel.Result result) {
|
||||
String key = methodCall.argument(KEY_ID);
|
||||
listeners.remove(key);
|
||||
if (listeners.isEmpty()) {
|
||||
initializedListener = false;
|
||||
// String key = methodCall.argument(KEY_ID);
|
||||
// listeners.remove(key);
|
||||
// if (listeners.isEmpty()) {
|
||||
// initializedListener = false;
|
||||
// Open_im_sdk.removeAdvancedMsgListener(sdkMsgListener);
|
||||
}
|
||||
// }
|
||||
}
|
||||
/*
|
||||
|
||||
|
@ -1087,7 +1087,6 @@ FOUNDATION_EXPORT const int64_t Open_im_sdkJoinGroupTip;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkKickGroupMemberTip;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLocation;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLoginFailed;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLoginInit;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLoginSuccess;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLogining;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkLogoutCmd;
|
||||
@ -1110,6 +1109,7 @@ FOUNDATION_EXPORT const int64_t Open_im_sdkQuote;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkRefuseFriendApplicationTip;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkRefuseGroupApplicationTip;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkRevoke;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkSdkInit;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkSetGroupInfoTip;
|
||||
FOUNDATION_EXPORT const int64_t Open_im_sdkSetSelfInfoTip;
|
||||
/**
|
||||
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user