主播聊天问题修复

This commit is contained in:
18401019693
2022-11-30 13:20:23 +08:00
parent f257c2b5a9
commit a41a58dc26
4 changed files with 22 additions and 26 deletions

View File

@@ -844,13 +844,13 @@ public abstract class LiveActivity extends AbsActivity implements SocketMessageL
* 打开聊天输入框
*/
public void openChatWindow() {
if (mKeyBoardHeightUtil == null) {
mKeyBoardHeightUtil = new KeyBoardHeightUtil2(mContext, super.findViewById(android.R.id.content), this);
mKeyBoardHeightUtil.start();
}
if (mLiveRoomViewHolder != null) {
mLiveRoomViewHolder.chatScrollToBottom();
}
// if (mKeyBoardHeightUtil == null) {
// mKeyBoardHeightUtil = new KeyBoardHeightUtil2(mContext, super.findViewById(android.R.id.content), this);
// mKeyBoardHeightUtil.start();
// }
// if (mLiveRoomViewHolder != null) {
// mLiveRoomViewHolder.chatScrollToBottom();
// }
LiveInputDialogFragment fragment = new LiveInputDialogFragment();
Bundle bundle = new Bundle();
bundle.putString(Constants.LIVE_DANMU_PRICE, mDanmuPrice);

View File

@@ -238,6 +238,9 @@ public class LiveInputDialogFragment extends AbsDialogFragment implements View.O
case GENERALMESSAGE:
((LiveActivity) mContext).sendChatMessage(content, atTextWatcher.getAtUserID(), atTextWatcher.getAtUserName());
atTextWatcher.clearMsg();
if (imm != null) {
imm.hideSoftInputFromWindow(mInput.getWindowToken(), 0);
}
dismiss();
break;
}