mirror of
https://github.com/jellyfin/jellyfin-expo.git
synced 2025-02-17 04:49:22 +00:00
Fix modals on player triggering screen orientation change
This commit is contained in:
parent
4139a0bd08
commit
3c75e9588f
@ -34,9 +34,18 @@ export default class HomeScreen extends React.Component {
|
||||
|
||||
onNavigationChange(navigation) {
|
||||
const url = new Url(navigation.url);
|
||||
console.debug('navigationChange', url);
|
||||
|
||||
let { isVideoPlaying } = this.state;
|
||||
// Modal windows in the player also trigger hash changes
|
||||
// Ignore any hashes that do not look start with '#!/'
|
||||
if (url.hash && url.hash.startsWith('#!/')) {
|
||||
isVideoPlaying = url.hash === '#!/videoosd.html';
|
||||
}
|
||||
|
||||
this.setState({
|
||||
url,
|
||||
isVideoPlaying: url.hash && url.hash === '#!/videoosd.html'
|
||||
isVideoPlaying
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user