full-screen: fix not re-entering full-screen after dialog is shown
This has the side effect of showing the bottom navbar when the toolbox is open, which is a nice thing since back is accessible.
This commit is contained in:
committed by
Saúl Ibarra Corretgé
parent
8dbd1ba1b7
commit
02131f3346
@@ -4,6 +4,7 @@ import { Immersive } from 'react-native-immersive';
|
||||
|
||||
import { APP_WILL_MOUNT, APP_WILL_UNMOUNT } from '../../base/app';
|
||||
import { getCurrentConference } from '../../base/conference';
|
||||
import { isAnyDialogOpen } from '../../base/dialog/functions';
|
||||
import { Platform } from '../../base/react';
|
||||
import { MiddlewareRegistry, StateListenerRegistry } from '../../base/redux';
|
||||
|
||||
@@ -48,8 +49,9 @@ StateListenerRegistry.register(
|
||||
/* selector */ state => {
|
||||
const { enabled: audioOnly } = state['features/base/audio-only'];
|
||||
const conference = getCurrentConference(state);
|
||||
const dialogOpen = isAnyDialogOpen(state);
|
||||
|
||||
return conference ? !audioOnly : false;
|
||||
return conference ? !audioOnly && !dialogOpen : false;
|
||||
},
|
||||
/* listener */ fullScreen => _setFullScreen(fullScreen)
|
||||
);
|
||||
@@ -70,7 +72,8 @@ function _onImmersiveChange({ getState }) {
|
||||
if (appState === 'active') {
|
||||
const { enabled: audioOnly } = state['features/base/audio-only'];
|
||||
const conference = getCurrentConference(state);
|
||||
const fullScreen = conference ? !audioOnly : false;
|
||||
const dialogOpen = isAnyDialogOpen(state);
|
||||
const fullScreen = conference ? !audioOnly && !dialogOpen : false;
|
||||
|
||||
_setFullScreen(fullScreen);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user