|  | @@ -3,6 +3,8 @@ package com.cooleshow.chatmodule.utils.helper;
 | 
	
		
			
				|  |  |  import android.os.Bundle;
 | 
	
		
			
				|  |  |  import android.text.TextUtils;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | +import com.cooleshow.base.utils.ToastUtil;
 | 
	
		
			
				|  |  | +import com.cooleshow.base.utils.UiUtils;
 | 
	
		
			
				|  |  |  import com.tencent.imsdk.v2.V2TIMConversation;
 | 
	
		
			
				|  |  |  import com.tencent.qcloud.tuicore.TUIConstants;
 | 
	
		
			
				|  |  |  import com.tencent.qcloud.tuicore.TUICore;
 | 
	
	
		
			
				|  | @@ -46,6 +48,9 @@ public class ChatHelper {
 | 
	
		
			
				|  |  |          if (TextUtils.isEmpty(targetId)) {
 | 
	
		
			
				|  |  |              return;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | +        if (UiUtils.isFastClick()) {
 | 
	
		
			
				|  |  | +            return;
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  |          Bundle param = new Bundle();
 | 
	
		
			
				|  |  |          param.putInt(TUIConstants.TUIChat.CHAT_TYPE, V2TIMConversation.V2TIM_C2C);
 | 
	
		
			
				|  |  |          param.putString(TUIConstants.TUIChat.CHAT_ID, targetId);
 | 
	
	
		
			
				|  | @@ -58,6 +63,9 @@ public class ChatHelper {
 | 
	
		
			
				|  |  |          if (TextUtils.isEmpty(targetId)) {
 | 
	
		
			
				|  |  |              return;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | +        if (UiUtils.isFastClick()) {
 | 
	
		
			
				|  |  | +            return;
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  |          Bundle param = new Bundle();
 | 
	
		
			
				|  |  |          param.putInt(TUIConstants.TUIChat.CHAT_TYPE, V2TIMConversation.V2TIM_GROUP);
 | 
	
		
			
				|  |  |          param.putString(TUIConstants.TUIChat.CHAT_ID, targetId);
 | 
	
	
		
			
				|  | @@ -65,6 +73,38 @@ public class ChatHelper {
 | 
	
		
			
				|  |  |          TUICore.startActivity(TUIConstants.TUIChat.GROUP_CHAT_ACTIVITY_NAME, param);
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | +    public void sendShareLiveMessage(String targetId, int targetConversationType, String liveRoomId, String teacherAvatar, String teacherName, String liveDes) {
 | 
	
		
			
				|  |  | +//        RCChatShareLiveMessage liveMessage = new RCChatShareLiveMessage();
 | 
	
		
			
				|  |  | +//
 | 
	
		
			
				|  |  | +//        liveMessage.setTeacherAvatar(teacherAvatar);
 | 
	
		
			
				|  |  | +//        liveMessage.setRoomUID(liveRoomId);
 | 
	
		
			
				|  |  | +//        liveMessage.setTeacherName(teacherName);
 | 
	
		
			
				|  |  | +//        liveMessage.setLiveDescMessage(liveDes);
 | 
	
		
			
				|  |  | +//        Conversation.ConversationType conversationType = getConversationType(targetConversationType);
 | 
	
		
			
				|  |  | +//        Message locationMsg = Message.obtain(targetId, conversationType, liveMessage);
 | 
	
		
			
				|  |  | +//        MessageTag annotation = liveMessage.getClass().getAnnotation(MessageTag.class);
 | 
	
		
			
				|  |  | +//        if (annotation != null) {
 | 
	
		
			
				|  |  | +//            locationMsg.setObjectName(annotation.value());
 | 
	
		
			
				|  |  | +//        }
 | 
	
		
			
				|  |  | +//        RongIM.getInstance().sendMessage(locationMsg, "直播分享", "[曲谱分享]", new IRongCallback.ISendMessageCallback() {
 | 
	
		
			
				|  |  | +//            @Override
 | 
	
		
			
				|  |  | +//            public void onAttached(Message message) {
 | 
	
		
			
				|  |  | +//
 | 
	
		
			
				|  |  | +//            }
 | 
	
		
			
				|  |  | +//
 | 
	
		
			
				|  |  | +//            @Override
 | 
	
		
			
				|  |  | +//            public void onSuccess(Message message) {
 | 
	
		
			
				|  |  | +//                ToastUtil.getInstance().showShort("分享成功");
 | 
	
		
			
				|  |  | +//            }
 | 
	
		
			
				|  |  | +//
 | 
	
		
			
				|  |  | +//            @Override
 | 
	
		
			
				|  |  | +//            public void onError(Message message, RongIMClient.ErrorCode errorCode) {
 | 
	
		
			
				|  |  | +//                ToastUtil.getInstance().showShort("分享失败");
 | 
	
		
			
				|  |  | +//            }
 | 
	
		
			
				|  |  | +//        });
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |      private static class ChatHelperHolder {
 | 
	
		
			
				|  |  |          public static ChatHelper mHelper = new ChatHelper();
 | 
	
		
			
				|  |  |      }
 |