void RemoveEventListenerSDK(string eventName) { switch (eventName) { case "AddRecvNewMsgCallback": { TencentIMSDK.RemoveRecvNewMsgCallback(); break; } case "SetMsgReadedReceiptCallback": { TencentIMSDK.SetMsgReadedReceiptCallback(); break; } case "SetMsgRevokeCallback": { TencentIMSDK.SetMsgRevokeCallback(); break; } case "SetGroupTipsEventCallback": { TencentIMSDK.SetGroupTipsEventCallback(); break; } case "SetMsgElemUploadProgressCallback": { TencentIMSDK.SetMsgElemUploadProgressCallback(); break; } default: { print($"Unknown event {eventName}"); break; } } EventListenerInfo.Info.Remove(eventName); Button btn = GameObject.Find(eventName).GetComponent <Button>(); RenderButton(eventName, btn); }