|
@@ -45,6 +45,7 @@ import {
|
45
|
45
|
RECORDING_ON_SOUND_FILE
|
46
|
46
|
} from './sounds';
|
47
|
47
|
|
|
48
|
+declare var APP: Object;
|
48
|
49
|
declare var interfaceConfig: Object;
|
49
|
50
|
|
50
|
51
|
/**
|
|
@@ -181,6 +182,10 @@ MiddlewareRegistry.register(({ dispatch, getState }) => next => action => {
|
181
|
182
|
if (soundID) {
|
182
|
183
|
dispatch(playSound(soundID));
|
183
|
184
|
}
|
|
185
|
+
|
|
186
|
+ if (typeof APP !== 'undefined') {
|
|
187
|
+ APP.API.notifyRecordingStatusChanged(true, mode);
|
|
188
|
+ }
|
184
|
189
|
} else if (updatedSessionData.status === OFF
|
185
|
190
|
&& (!oldSessionData || oldSessionData.status !== OFF)) {
|
186
|
191
|
dispatch(showStoppedRecordingNotification(
|
|
@@ -209,6 +214,10 @@ MiddlewareRegistry.register(({ dispatch, getState }) => next => action => {
|
209
|
214
|
dispatch(stopSound(soundOn));
|
210
|
215
|
dispatch(playSound(soundOff));
|
211
|
216
|
}
|
|
217
|
+
|
|
218
|
+ if (typeof APP !== 'undefined') {
|
|
219
|
+ APP.API.notifyRecordingStatusChanged(false, mode);
|
|
220
|
+ }
|
212
|
221
|
}
|
213
|
222
|
}
|
214
|
223
|
|
|
@@ -231,11 +240,11 @@ MiddlewareRegistry.register(({ dispatch, getState }) => next => action => {
|
231
|
240
|
* @returns {void}
|
232
|
241
|
*/
|
233
|
242
|
function _showRecordingErrorNotification(recorderSession, dispatch) {
|
234
|
|
- const isStreamMode
|
235
|
|
- = recorderSession.getMode()
|
236
|
|
- === JitsiMeetJS.constants.recording.mode.STREAM;
|
|
243
|
+ const mode = recorderSession.getMode();
|
|
244
|
+ const error = recorderSession.getError();
|
|
245
|
+ const isStreamMode = mode === JitsiMeetJS.constants.recording.mode.STREAM;
|
237
|
246
|
|
238
|
|
- switch (recorderSession.getError()) {
|
|
247
|
+ switch (error) {
|
239
|
248
|
case JitsiMeetJS.constants.recording.error.SERVICE_UNAVAILABLE:
|
240
|
249
|
dispatch(showRecordingError({
|
241
|
250
|
descriptionKey: 'recording.unavailable',
|
|
@@ -270,4 +279,8 @@ function _showRecordingErrorNotification(recorderSession, dispatch) {
|
270
|
279
|
}));
|
271
|
280
|
break;
|
272
|
281
|
}
|
|
282
|
+
|
|
283
|
+ if (typeof APP !== 'undefined') {
|
|
284
|
+ APP.API.notifyRecordingStatusChanged(false, mode, error);
|
|
285
|
+ }
|
273
|
286
|
}
|