fix: private message open

This commit is contained in:
Bettenbuk Zoltan 2020-04-22 11:33:49 +02:00 committed by Zoltan Bettenbuk
parent 147a076f5d
commit cd1862a2d3
1 changed files with 9 additions and 1 deletions

View File

@ -10,6 +10,7 @@ import {
JitsiConferenceErrors, JitsiConferenceErrors,
JitsiConferenceEvents JitsiConferenceEvents
} from '../base/lib-jitsi-meet'; } from '../base/lib-jitsi-meet';
import { setActiveModalId } from '../base/modal';
import { import {
getLocalParticipant, getLocalParticipant,
getParticipantById, getParticipantById,
@ -22,7 +23,13 @@ import { isButtonEnabled, showToolbox } from '../toolbox';
import { SEND_MESSAGE, SET_PRIVATE_MESSAGE_RECIPIENT } from './actionTypes'; import { SEND_MESSAGE, SET_PRIVATE_MESSAGE_RECIPIENT } from './actionTypes';
import { addMessage, clearMessages, toggleChat } from './actions'; import { addMessage, clearMessages, toggleChat } from './actions';
import { ChatPrivacyDialog } from './components'; import { ChatPrivacyDialog } from './components';
import { INCOMING_MSG_SOUND_ID, MESSAGE_TYPE_ERROR, MESSAGE_TYPE_LOCAL, MESSAGE_TYPE_REMOTE } from './constants'; import {
CHAT_VIEW_MODAL_ID,
INCOMING_MSG_SOUND_ID,
MESSAGE_TYPE_ERROR,
MESSAGE_TYPE_LOCAL,
MESSAGE_TYPE_REMOTE
} from './constants';
import { INCOMING_MSG_SOUND_FILE } from './sounds'; import { INCOMING_MSG_SOUND_FILE } from './sounds';
declare var APP: Object; declare var APP: Object;
@ -94,6 +101,7 @@ MiddlewareRegistry.register(store => next => action => {
} }
case SET_PRIVATE_MESSAGE_RECIPIENT: { case SET_PRIVATE_MESSAGE_RECIPIENT: {
Boolean(action.participant) && dispatch(setActiveModalId(CHAT_VIEW_MODAL_ID));
_maybeFocusField(); _maybeFocusField();
break; break;
} }