mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-06 03:50:04 +02:00
This commit is contained in:
parent
fc04391c27
commit
82b14f09af
2 changed files with 7 additions and 8 deletions
|
@ -58,6 +58,10 @@ class TheaterButton extends PluginAbstract {
|
|||
return "";
|
||||
}
|
||||
$obj = $this->getDataObject();
|
||||
|
||||
if (!empty($obj->show_switch_button)) {
|
||||
return array("plugin/TheaterButton/script.js", "plugin/TheaterButton/addButton.js");
|
||||
}
|
||||
return array("plugin/TheaterButton/script.js");
|
||||
}
|
||||
|
||||
|
@ -70,11 +74,11 @@ class TheaterButton extends PluginAbstract {
|
|||
$js = '';
|
||||
if (!empty($obj->show_switch_button)) {
|
||||
if ($obj->compress_is_default) {
|
||||
$js .= '<script>compress_is_default=true</script>';
|
||||
PlayerSkins::getStartPlayerJS(file_get_contents("compress(player);"));
|
||||
} else {
|
||||
$js .= '<script>compress_is_default=false</script>';
|
||||
PlayerSkins::getStartPlayerJS(file_get_contents("expand(player);"));
|
||||
}
|
||||
PlayerSkins::getStartPlayerJS(file_get_contents("{$global['systemRootPath']}plugin/TheaterButton/addButton.js"));
|
||||
|
||||
}
|
||||
|
||||
return $js;
|
||||
|
|
|
@ -24,8 +24,3 @@ if (player.getChild('controlBar').getChild('PictureInPictureToggle')) {
|
|||
}
|
||||
|
||||
|
||||
if (compress_is_default) {
|
||||
compress(player);
|
||||
} else {
|
||||
expand(player);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue