feat(api): expose method for playing touch tones (#4584)

This commit is contained in:
virtuacoplenny
2019-08-30 14:17:22 -07:00
committed by GitHub
parent bd99108e8e
commit 55ff9dbe80
6 changed files with 84 additions and 1 deletions

View File

@@ -5,7 +5,11 @@ import {
createApiEvent,
sendAnalytics
} from '../../react/features/analytics';
import { setPassword, setSubject } from '../../react/features/base/conference';
import {
sendTones,
setPassword,
setSubject
} from '../../react/features/base/conference';
import { parseJWTFromURLParams } from '../../react/features/base/jwt';
import { invite } from '../../react/features/invite';
import { toggleTileView } from '../../react/features/video-layout';
@@ -90,6 +94,11 @@ function initCommands() {
'proxy-connection-event': event => {
APP.conference.onProxyConnectionEvent(event);
},
'send-tones': (options = {}) => {
const { duration, tones, pause } = options;
APP.store.dispatch(sendTones(tones, duration, pause));
},
'subject': subject => {
sendAnalytics(createApiEvent('subject.changed'));
APP.store.dispatch(setSubject(subject));