mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-07-09 03:04:20 -04:00
Resolving a bug with the player in the mobile version.
This commit is contained in:
parent
492329149f
commit
000b5a7799
@ -63,7 +63,7 @@ export class PlayerComponent implements OnInit
|
||||
|
||||
this.title.setTitle(this.item.showTitle + " S" + this.item.seasonNumber + ":E" + this.item.episodeNumber + " - Kyoo");
|
||||
|
||||
if (navigator.userAgent.match(/Mobi/))
|
||||
if (navigator.userAgent.match(/Mobi/) && document.fullscreenElement == null)
|
||||
{
|
||||
this.fullscreen();
|
||||
screen.orientation.lock("landscape");
|
||||
@ -81,9 +81,6 @@ export class PlayerComponent implements OnInit
|
||||
this.progress = document.getElementById("progress") as HTMLElement;
|
||||
this.buffered = document.getElementById("buffered") as HTMLElement;
|
||||
this.player.controls = false;
|
||||
//console.log(this.player.volume * 100);
|
||||
//this.volume = this.player.volume * 100;
|
||||
//this.changeVolumeBtn();
|
||||
|
||||
this.player.onplay = () =>
|
||||
{
|
||||
@ -206,7 +203,7 @@ export class PlayerComponent implements OnInit
|
||||
{
|
||||
if (navigator.userAgent.match(/Mobi/))
|
||||
{
|
||||
if (document.fullscreenElement == null)
|
||||
if (document.fullscreenElement == null && this.router.url.startsWith("/watch"))
|
||||
this.back();
|
||||
}
|
||||
else
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { Component, OnInit, OnDestroy } from '@angular/core';
|
||||
import { ActivatedRoute } from "@angular/router";
|
||||
import { SearchResut } from "../../models/search-result";
|
||||
import { Title } from "@angular/platform-browser";
|
||||
@ -8,7 +8,7 @@ import { Title } from "@angular/platform-browser";
|
||||
templateUrl: './search.component.html',
|
||||
styleUrls: ['./search.component.scss']
|
||||
})
|
||||
export class SearchComponent implements OnInit
|
||||
export class SearchComponent implements OnInit, OnDestroy
|
||||
{
|
||||
items: SearchResut;
|
||||
|
||||
@ -29,4 +29,11 @@ export class SearchComponent implements OnInit
|
||||
searchBar.classList.add("searching");
|
||||
searchBar.value = this.items.query;
|
||||
}
|
||||
|
||||
ngOnDestroy()
|
||||
{
|
||||
let searchBar: HTMLInputElement = <HTMLInputElement>document.getElementById("search");
|
||||
searchBar.classList.remove("searching");
|
||||
searchBar.value = "";
|
||||
}
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ import { Show } from "../../models/show";
|
||||
@Injectable()
|
||||
export class LibraryResolverService implements Resolve<Show[]>
|
||||
{
|
||||
constructor(private http: HttpClient, private snackBar: MatSnackBar) { console.log("Library Resolver Created"); }
|
||||
constructor(private http: HttpClient, private snackBar: MatSnackBar) { }
|
||||
|
||||
resolve(route: ActivatedRouteSnapshot): Show[] | Observable<Show[]> | Promise<Show[]>
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user