|
|
@@ -21,14 +21,10 @@ export function enterPictureInPicture() {
|
|
21
|
21
|
const state = getState();
|
|
22
|
22
|
const { app } = state['features/app'];
|
|
23
|
23
|
|
|
24
|
|
- // FIXME We want to be able to enter Picture-in-Picture as soon as we
|
|
25
|
|
- // are on the Conference page i.e. even before `joining` was set in the
|
|
26
|
|
- // reducer.
|
|
27
|
|
- const { conference, joining } = state['features/base/conference'];
|
|
28
|
|
-
|
|
29
|
|
- if (app
|
|
30
|
|
- && app.props.pictureInPictureEnabled
|
|
31
|
|
- && (conference || joining)) {
|
|
|
24
|
+ // XXX At the time of this writing this action can only be dispatched by
|
|
|
25
|
+ // the button which is on the conference view, which means that it's
|
|
|
26
|
+ // fine to enter PiP mode.
|
|
|
27
|
+ if (app && app.props.pictureInPictureEnabled) {
|
|
32
|
28
|
const { PictureInPicture } = NativeModules;
|
|
33
|
29
|
const p
|
|
34
|
30
|
= Platform.OS === 'android'
|