fml toggle update
This commit is contained in:
parent
3c784505d2
commit
cd475c6508
@ -205,7 +205,7 @@ class ActionsMenu implements CallbackListener, ManialinkPageAnswerListener {
|
||||
$backgroundQuad->setStyles($quadStyle, $quadSubstyle);
|
||||
$backgroundQuad->setSize(count($this->adminMenuItems) * $itemSize * 1.15 + 2, $itemSize * $itemMarginFactorY);
|
||||
|
||||
$script->addTooltip($itemQuad, $popoutFrame, Script::OPTION_TOOLTIP_ONCLICK);
|
||||
$script->addToggle($itemQuad, $popoutFrame);
|
||||
|
||||
// Add items
|
||||
$x = -1;
|
||||
@ -273,7 +273,7 @@ class ActionsMenu implements CallbackListener, ManialinkPageAnswerListener {
|
||||
$backgroundQuad->setStyles($quadStyle, $quadSubstyle);
|
||||
$backgroundQuad->setSize(count($this->playerMenuItems) * $itemSize * 1.15 + 2, $itemSize * $itemMarginFactorY);
|
||||
|
||||
$script->addTooltip($itemQuad, $popoutFrame, Script::OPTION_TOOLTIP_ONCLICK);
|
||||
$script->addToggle($itemQuad, $popoutFrame);
|
||||
|
||||
// Add items
|
||||
$x = -1;
|
||||
|
@ -297,6 +297,12 @@ class Script {
|
||||
return $this;
|
||||
}
|
||||
$toggleControl->checkId();
|
||||
if ($mode == self::CLASS_HIDE) {
|
||||
$toggleControl->setVisible(true);
|
||||
}
|
||||
else {
|
||||
$toggleControl->setVisible(false);
|
||||
}
|
||||
$clickControl->setScriptEvents(true);
|
||||
$clickControl->addClass(self::CLASS_TOGGLE);
|
||||
$clickControl->addClass($mode);
|
||||
|
@ -191,8 +191,7 @@ class DonationPlugin implements CallbackListener, CommandListener, Plugin {
|
||||
$itemSize = $width;
|
||||
|
||||
$maniaLink = new ManiaLink(self::MLID_DONATE_WIDGET);
|
||||
$script = new Script();
|
||||
$maniaLink->setScript($script);
|
||||
$script = $maniaLink->getScript();
|
||||
|
||||
// Donate Menu Icon Frame
|
||||
$frame = new Frame();
|
||||
@ -230,7 +229,7 @@ class DonationPlugin implements CallbackListener, CommandListener, Plugin {
|
||||
|
||||
$popoutFrame->add($quad);
|
||||
|
||||
$script->addTooltip($itemQuad, $popoutFrame, Script::OPTION_TOOLTIP_ONCLICK);
|
||||
$script->addToggle($itemQuad, $popoutFrame);
|
||||
|
||||
// Description Label
|
||||
$descriptionFrame = new Frame();
|
||||
|
Loading…
Reference in New Issue
Block a user