small fixes
This commit is contained in:
parent
483d673e5f
commit
7a6566691c
@ -273,11 +273,13 @@ class ManiaLink {
|
||||
$stylesheetXml = $this->stylesheet->render($domDocument);
|
||||
$maniaLink->appendChild($stylesheetXml);
|
||||
}
|
||||
if ($this->script->needsRendering()) {
|
||||
$scriptXml = $this->script->render($domDocument);
|
||||
$maniaLink->appendChild($scriptXml);
|
||||
if ($this->script) {
|
||||
if ($this->script->needsRendering()) {
|
||||
$scriptXml = $this->script->render($domDocument);
|
||||
$maniaLink->appendChild($scriptXml);
|
||||
}
|
||||
$this->script->resetGenericScriptLabels();
|
||||
}
|
||||
$this->script->resetGenericScriptLabels();
|
||||
if ($isChild) {
|
||||
return $maniaLink;
|
||||
}
|
||||
|
@ -180,6 +180,9 @@ class Paging extends ScriptFeature {
|
||||
* @see \FML\Script\Features\ScriptFeature::prepare()
|
||||
*/
|
||||
public function prepare(Script $script) {
|
||||
if (!$this->pages) {
|
||||
return $this;
|
||||
}
|
||||
$script->setScriptInclude(ScriptInclude::TEXTLIB);
|
||||
|
||||
$currentPageVariable = self::VAR_CURRENT_PAGE;
|
||||
@ -270,6 +273,7 @@ Void {$updatePageFunction}(Text _PagingId, Text _PageLabelId, Integer _BrowseAct
|
||||
protected function getMinPage() {
|
||||
$minPageNumber = null;
|
||||
$minPage = null;
|
||||
var_dump($this->pages);
|
||||
foreach ($this->pages as $page) {
|
||||
$pageNumber = $page->getPageNumber();
|
||||
if ($minPageNumber === null || $pageNumber < $minPageNumber) {
|
||||
|
@ -60,8 +60,6 @@ class PluginInstallMenu implements CallbackListener, ConfiguratorMenu, Manialink
|
||||
*/
|
||||
public function getMenu($width, $height, Script $script) {
|
||||
$paging = new Paging();
|
||||
$script->addFeature($paging);
|
||||
$paging = new Paging();
|
||||
$script->addFeature($paging);
|
||||
$frame = new Frame();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user