|
|
|
@ -3,6 +3,7 @@ |
|
|
|
import { StatusBar } from 'react-native'; |
|
|
|
import { StatusBar } from 'react-native'; |
|
|
|
import { Immersive } from 'react-native-immersive'; |
|
|
|
import { Immersive } from 'react-native-immersive'; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import { APP_STATE_CHANGED } from '../background'; |
|
|
|
import { |
|
|
|
import { |
|
|
|
CONFERENCE_FAILED, |
|
|
|
CONFERENCE_FAILED, |
|
|
|
CONFERENCE_LEFT, |
|
|
|
CONFERENCE_LEFT, |
|
|
|
@ -23,9 +24,20 @@ import { MiddlewareRegistry } from '../base/redux'; |
|
|
|
* @returns {Function} |
|
|
|
* @returns {Function} |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
MiddlewareRegistry.register(store => next => action => { |
|
|
|
MiddlewareRegistry.register(store => next => action => { |
|
|
|
let fullScreen; |
|
|
|
let fullScreen = null; |
|
|
|
|
|
|
|
|
|
|
|
switch (action.type) { |
|
|
|
switch (action.type) { |
|
|
|
|
|
|
|
case APP_STATE_CHANGED: { |
|
|
|
|
|
|
|
// Check if we just came back from the background and reenable full
|
|
|
|
|
|
|
|
// screen mode if necessary.
|
|
|
|
|
|
|
|
if (action.appState === 'active') { |
|
|
|
|
|
|
|
const conference = store.getState()['features/base/conference']; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
fullScreen = conference ? !conference.audioOnly : false; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
case CONFERENCE_WILL_JOIN: { |
|
|
|
case CONFERENCE_WILL_JOIN: { |
|
|
|
const conference = store.getState()['features/base/conference']; |
|
|
|
const conference = store.getState()['features/base/conference']; |
|
|
|
|
|
|
|
|
|
|
|
@ -37,10 +49,6 @@ MiddlewareRegistry.register(store => next => action => { |
|
|
|
case CONFERENCE_LEFT: |
|
|
|
case CONFERENCE_LEFT: |
|
|
|
fullScreen = false; |
|
|
|
fullScreen = false; |
|
|
|
break; |
|
|
|
break; |
|
|
|
|
|
|
|
|
|
|
|
default: |
|
|
|
|
|
|
|
fullScreen = null; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (fullScreen !== null) { |
|
|
|
if (fullScreen !== null) { |
|
|
|
|