mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-07-09 03:04:20 -04:00
Solving quick bugs with the web player.
This commit is contained in:
parent
604c68721b
commit
d99c3f0e08
@ -1,7 +1,7 @@
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { MatSnackBar } from "@angular/material/snack-bar";
|
||||
import { DomSanitizer, Title } from "@angular/platform-browser";
|
||||
import { ActivatedRoute, Router } from "@angular/router";
|
||||
import { Event, ActivatedRoute, Router, NavigationStart } from "@angular/router";
|
||||
import { Track, WatchItem } from "../../models/watch-item";
|
||||
|
||||
declare var SubtitleManager: any;
|
||||
@ -194,12 +194,12 @@ export class PlayerComponent implements OnInit
|
||||
if (document.fullscreenElement != null)
|
||||
{
|
||||
this.fullscreenIcon = "fullscreen_exit";
|
||||
$("#fullscreen").attr("data-original-title", "Exit fullscreen").tooltip("show");
|
||||
$("#fullscreen").attr("data-original-title", "Exit fullscreen");
|
||||
}
|
||||
else
|
||||
{
|
||||
this.fullscreenIcon = "fullscreen";
|
||||
$("#fullscreen").attr("data-original-title", "Fullscreen").tooltip("show");
|
||||
$("#fullscreen").attr("data-original-title", "Fullscreen");
|
||||
}
|
||||
});
|
||||
|
||||
@ -249,7 +249,7 @@ export class PlayerComponent implements OnInit
|
||||
|
||||
case 80: //P key
|
||||
if (this.item.previousEpisode != null)
|
||||
this.router.navigate(["/watch/" + this.item.previousEpisode], { queryParamsHandling: "merge" });
|
||||
this.router.navigate(["/watch/" + this.item.previousEpisode], { queryParamsHandling: "merge" });
|
||||
break;
|
||||
|
||||
default:
|
||||
@ -257,6 +257,20 @@ export class PlayerComponent implements OnInit
|
||||
}
|
||||
});
|
||||
|
||||
this.router.events.subscribe((event: Event) =>
|
||||
{
|
||||
switch (true)
|
||||
{
|
||||
case event instanceof NavigationStart:
|
||||
{
|
||||
loadIndicator.classList.remove("d-none");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
});
|
||||
|
||||
$('[data-toggle="tooltip"]').tooltip({ trigger: "hover" });
|
||||
|
||||
this.init();
|
||||
@ -306,12 +320,14 @@ export class PlayerComponent implements OnInit
|
||||
|
||||
ngOnDestroy()
|
||||
{
|
||||
if (document.fullscreen)
|
||||
document.exitFullscreen();
|
||||
|
||||
document.getElementById("nav").classList.remove("d-none");
|
||||
this.title.setTitle("Kyoo");
|
||||
|
||||
$(document).unbind();
|
||||
$(window).unbind();
|
||||
document.exitFullscreen();
|
||||
$('[data-toggle="tooltip"]').hide();
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"databasePath": "C://Projects/database.db",
|
||||
"tempPath": "C:\\Projects",
|
||||
"tempPath": "C://Projects/temp",
|
||||
"peoplePath": "D://Videos/People",
|
||||
"plugins": "C:\\Projects\\Kyoo\\Debug",
|
||||
"providerPlugins": "C://Projects/Plugins/Providers",
|
||||
|
Loading…
x
Reference in New Issue
Block a user