1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 01:39:24 +02:00
This commit is contained in:
DanieL 2022-12-30 10:06:43 -03:00
parent 49d1a93ad0
commit e170e053e1
6 changed files with 34 additions and 2 deletions

1
.gitignore vendored
View file

@ -83,3 +83,4 @@ objects/ezyang/
view/videoComments_bkp.php
/.compose/
test.php
/plugin/JosephZ/

View file

@ -2411,6 +2411,23 @@ class AVideoPlugin
return;
}
public static function getMobileHomePageURL()
{
$plugins = Plugin::getAllEnabled();
foreach ($plugins as $value) {
self::YPTstart();
$p = static::loadPlugin($value['dirName']);
if (is_object($p)) {
$url = $p->getMobileHomePageURL();
if(isValidURL($url)){
return $url;
}
}
self::YPTend("{$value['dirName']}::" . __FUNCTION__);
}
return false;
}
public static function getPluginsOnByDefault($getUUID = true)
{
if (empty($getUUID)) {

View file

@ -18,6 +18,8 @@ if(!empty($chat2)){
$objMM->chat2ShowOnUserVideos = false;
}
$objMM->homePageURL = AVideoPlugin::getMobileHomePageURL();
$objMM->logo = getURL($config->getLogo());
$objMM->favicon = $config->getFavicon(true);
$objMM->title = $config->getWebSiteTitle();

View file

@ -794,6 +794,10 @@ abstract class PluginAbstract {
}
function getMobileHomePageURL() {
return false;
}
function updateParameter($parameterName, $newValue) {
$pluginDO = $this->getDataObject();
$pluginDB = Plugin::getPluginByName($this->getName());

View file

@ -3710,7 +3710,8 @@ async function sendAVideoMobileLiveStreamerMessage(type, value){
}, 1000);
}
} else {
console.log('sendAVideoMobileLiveStreamerMessage error', type, value);
//window.parent.postMessage({type: type, value: value}, '*');
window.top.postMessage({type: type, value: value}, '*');
}
}
window.addEventListener("flutterInAppWebViewPlatformReady", function (event) {

View file

@ -30,7 +30,14 @@ if (User::isLogged()) {
<?php include $global['systemRootPath'] . 'view/include/navbar.php'; ?>
<div class="container-fluid">
<?php include $global['systemRootPath'] . 'view/userLogin.php'; ?>
<?php
if(User::isLogged()){
include $global['systemRootPath'] . 'view/userBody.php';
}else{
include $global['systemRootPath'] . 'view/userLogin.php';
}
?>
</div><!--/.container-->
<?php