fix: 🚑 Fix pressing back button in fullscreen exiting the player

fix #359
This commit is contained in:
Kenny 2022-08-06 11:33:47 -04:00
parent fad4bb27dd
commit 5a6119d5d4
1 changed files with 10 additions and 0 deletions

View File

@ -354,6 +354,9 @@ import fscontrols from "~/components/Player/fscontrols.vue";
import fullscreen from "~/components/Player/fullscreen.vue";
import progressbar from "~/components/Player/progressbar.vue";
import sponsorblock from "~/components/Player/sponsorblock.vue";
import backType from "~/plugins/classes/backType";
export default {
components: {
sponsorblock,
@ -683,6 +686,13 @@ export default {
this.$vuetube.navigationBar.hide();
this.$vuetube.statusBar.hide();
this.isFullscreen = true;
//--- Fix pressing back button in fullscreen exiting the player ---//
this.$vuetube.addBackAction(new backType(
() => { this.exitFullscreen(true); },
() => { return this.isFullscreen; }
));
},
getPlayer() {
return this.$refs.player;