FML Update
This commit is contained in:
parent
edd62f0eb4
commit
8b3667b252
@ -43,7 +43,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
* Set the name
|
* Set the name
|
||||||
*
|
*
|
||||||
* @param string $name CheckBox name
|
* @param string $name CheckBox name
|
||||||
* @return \FML\Components\CheckBox|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -54,7 +54,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
* Set the default value
|
* Set the default value
|
||||||
*
|
*
|
||||||
* @param bool $default Default value
|
* @param bool $default Default value
|
||||||
* @return \FML\Components\CheckBox|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDefault($default) {
|
public function setDefault($default) {
|
||||||
$this->feature->setDefault($default);
|
$this->feature->setDefault($default);
|
||||||
@ -66,7 +66,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $style Style name or image url
|
* @param string $style Style name or image url
|
||||||
* @param string $subStyle SubStyle name
|
* @param string $subStyle SubStyle name
|
||||||
* @return \FML\Components\CheckBox|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEnabledDesign($style, $subStyle = null) {
|
public function setEnabledDesign($style, $subStyle = null) {
|
||||||
if (is_object($style) && ($style instanceof CheckBoxDesign)) {
|
if (is_object($style) && ($style instanceof CheckBoxDesign)) {
|
||||||
@ -83,7 +83,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $style Style name or image url
|
* @param string $style Style name or image url
|
||||||
* @param string $subStyle SubStyle name
|
* @param string $subStyle SubStyle name
|
||||||
* @return \FML\Components\CheckBox|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDisabledDesign($style, $subStyle = null) {
|
public function setDisabledDesign($style, $subStyle = null) {
|
||||||
if (is_object($style) && ($style instanceof CheckBoxDesign)) {
|
if (is_object($style) && ($style instanceof CheckBoxDesign)) {
|
||||||
@ -99,7 +99,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
* Set the CheckBox Quad
|
* Set the CheckBox Quad
|
||||||
*
|
*
|
||||||
* @param Quad $quad CheckBox Quad
|
* @param Quad $quad CheckBox Quad
|
||||||
* @return \FML\Components\CheckBox|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setQuad(Quad $quad = null) {
|
public function setQuad(Quad $quad = null) {
|
||||||
$this->feature->setQuad($quad);
|
$this->feature->setQuad($quad);
|
||||||
@ -129,7 +129,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \ManiaControl\Types\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$frame = new Frame();
|
$frame = new Frame();
|
||||||
@ -147,7 +147,7 @@ class CheckBox implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Build the hidden Entry
|
* Build the hidden Entry
|
||||||
*
|
*
|
||||||
* @return Entry
|
* @return \FML\Controls\Entry
|
||||||
*/
|
*/
|
||||||
protected function buildEntry() {
|
protected function buildEntry() {
|
||||||
$entry = new Entry();
|
$entry = new Entry();
|
||||||
|
@ -44,7 +44,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
* Set Name
|
* Set Name
|
||||||
*
|
*
|
||||||
* @param string $name ValuePicker name
|
* @param string $name ValuePicker name
|
||||||
* @return \FML\Components\ValuePicker|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -55,7 +55,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
* Set the possible values
|
* Set the possible values
|
||||||
*
|
*
|
||||||
* @param array $values Possible values
|
* @param array $values Possible values
|
||||||
* @return \FML\Components\ValuePicker|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setValues(array $values) {
|
public function setValues(array $values) {
|
||||||
$this->feature->setValues($values);
|
$this->feature->setValues($values);
|
||||||
@ -66,7 +66,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
* Set the default value
|
* Set the default value
|
||||||
*
|
*
|
||||||
* @param bool $default Default value
|
* @param bool $default Default value
|
||||||
* @return \FML\Components\ValuePicker|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDefault($default) {
|
public function setDefault($default) {
|
||||||
$this->feature->setDefault($default);
|
$this->feature->setDefault($default);
|
||||||
@ -77,7 +77,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
* Set the ValuePicker Label
|
* Set the ValuePicker Label
|
||||||
*
|
*
|
||||||
* @param Label $label ValuePicker Label
|
* @param Label $label ValuePicker Label
|
||||||
* @return \FML\Components\ValuePicker|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabel(Label $label = null) {
|
public function setLabel(Label $label = null) {
|
||||||
$this->feature->setLabel($label);
|
$this->feature->setLabel($label);
|
||||||
@ -106,7 +106,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \ManiaControl\Types\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$frame = new Frame();
|
$frame = new Frame();
|
||||||
@ -124,7 +124,7 @@ class ValuePicker implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Build the hidden Entry
|
* Build the hidden Entry
|
||||||
*
|
*
|
||||||
* @return Entry
|
* @return \FML\Controls\Entry
|
||||||
*/
|
*/
|
||||||
protected function buildEntry() {
|
protected function buildEntry() {
|
||||||
$entry = new Entry();
|
$entry = new Entry();
|
||||||
|
@ -59,7 +59,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Create a new Control object
|
* Create a new Control object
|
||||||
*
|
*
|
||||||
* @param string $controlId (optional) Control id
|
* @param string $controlId (optional) Control id
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($controlId = null) {
|
public static function create($controlId = null) {
|
||||||
return new static($controlId);
|
return new static($controlId);
|
||||||
@ -80,7 +80,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Check Id for dangerous characters and assign a new unique id if necessary
|
* Check Id for dangerous characters and assign a new unique id if necessary
|
||||||
*
|
*
|
||||||
* @param bool $forceNewId (optional) Whether to force setting a newly generated id
|
* @param bool $forceNewId (optional) Whether to force setting a newly generated id
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function checkId($forceNewId = false) {
|
public function checkId($forceNewId = false) {
|
||||||
if ($forceNewId || !$this->getId()) {
|
if ($forceNewId || !$this->getId()) {
|
||||||
@ -123,7 +123,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Control id
|
* Set Control id
|
||||||
*
|
*
|
||||||
* @param string $controlId Control id
|
* @param string $controlId Control id
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setId($controlId) {
|
public function setId($controlId) {
|
||||||
$this->controlId = (string)$controlId;
|
$this->controlId = (string)$controlId;
|
||||||
@ -136,7 +136,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* @param float $posX Horizontal position
|
* @param float $posX Horizontal position
|
||||||
* @param float $posY Vertical position
|
* @param float $posY Vertical position
|
||||||
* @param float $posZ (optional) Depth
|
* @param float $posZ (optional) Depth
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setPosition($posX, $posY, $posZ = null) {
|
public function setPosition($posX, $posY, $posZ = null) {
|
||||||
$this->setX($posX);
|
$this->setX($posX);
|
||||||
@ -151,7 +151,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set X position
|
* Set X position
|
||||||
*
|
*
|
||||||
* @param float $posX Horizontal position
|
* @param float $posX Horizontal position
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setX($posX) {
|
public function setX($posX) {
|
||||||
$this->posX = (float)$posX;
|
$this->posX = (float)$posX;
|
||||||
@ -162,7 +162,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Y position
|
* Set Y position
|
||||||
*
|
*
|
||||||
* @param float $posY Vertical position
|
* @param float $posY Vertical position
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setY($posY) {
|
public function setY($posY) {
|
||||||
$this->posY = (float)$posY;
|
$this->posY = (float)$posY;
|
||||||
@ -173,7 +173,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Z position
|
* Set Z position
|
||||||
*
|
*
|
||||||
* @param float $posZ Depth
|
* @param float $posZ Depth
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setZ($posZ) {
|
public function setZ($posZ) {
|
||||||
$this->posZ = (float)$posZ;
|
$this->posZ = (float)$posZ;
|
||||||
@ -185,7 +185,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param float $width Control width
|
* @param float $width Control width
|
||||||
* @param float $height Control height
|
* @param float $height Control height
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setSize($width, $height) {
|
public function setSize($width, $height) {
|
||||||
$this->setWidth($width);
|
$this->setWidth($width);
|
||||||
@ -197,7 +197,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Control width
|
* Set Control width
|
||||||
*
|
*
|
||||||
* @param float $width Control width
|
* @param float $width Control width
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setWidth($width) {
|
public function setWidth($width) {
|
||||||
$this->width = (float)$width;
|
$this->width = (float)$width;
|
||||||
@ -208,7 +208,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Control height
|
* Set Control height
|
||||||
*
|
*
|
||||||
* @param float $height Control height
|
* @param float $height Control height
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setHeight($height) {
|
public function setHeight($height) {
|
||||||
$this->height = (float)$height;
|
$this->height = (float)$height;
|
||||||
@ -218,7 +218,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Center alignment
|
* Center alignment
|
||||||
*
|
*
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function centerAlign() {
|
public function centerAlign() {
|
||||||
$this->setAlign(self::CENTER, self::CENTER2);
|
$this->setAlign(self::CENTER, self::CENTER2);
|
||||||
@ -230,7 +230,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $hAlign Horizontal alignment
|
* @param string $hAlign Horizontal alignment
|
||||||
* @param string $vAlign Vertical alignment
|
* @param string $vAlign Vertical alignment
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAlign($hAlign, $vAlign) {
|
public function setAlign($hAlign, $vAlign) {
|
||||||
$this->setHAlign($hAlign);
|
$this->setHAlign($hAlign);
|
||||||
@ -242,7 +242,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set horizontal alignment
|
* Set horizontal alignment
|
||||||
*
|
*
|
||||||
* @param string $hAlign Horizontal alignment
|
* @param string $hAlign Horizontal alignment
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setHAlign($hAlign) {
|
public function setHAlign($hAlign) {
|
||||||
$this->hAlign = (string)$hAlign;
|
$this->hAlign = (string)$hAlign;
|
||||||
@ -253,7 +253,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set vertical alignment
|
* Set vertical alignment
|
||||||
*
|
*
|
||||||
* @param string $vAlign Vertical alignment
|
* @param string $vAlign Vertical alignment
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setVAlign($vAlign) {
|
public function setVAlign($vAlign) {
|
||||||
$this->vAlign = (string)$vAlign;
|
$this->vAlign = (string)$vAlign;
|
||||||
@ -263,7 +263,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Reset alignment
|
* Reset alignment
|
||||||
*
|
*
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function resetAlign() {
|
public function resetAlign() {
|
||||||
$this->setAlign(null, null);
|
$this->setAlign(null, null);
|
||||||
@ -274,7 +274,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set Control scale
|
* Set Control scale
|
||||||
*
|
*
|
||||||
* @param float $scale Control scale
|
* @param float $scale Control scale
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setScale($scale) {
|
public function setScale($scale) {
|
||||||
$this->scale = (float)$scale;
|
$this->scale = (float)$scale;
|
||||||
@ -285,7 +285,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Set visibility
|
* Set visibility
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the Control should be visible
|
* @param bool $visible Whether the Control should be visible
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setVisible($visible = true) {
|
public function setVisible($visible = true) {
|
||||||
$this->hidden = ($visible ? 0 : 1);
|
$this->hidden = ($visible ? 0 : 1);
|
||||||
@ -295,8 +295,8 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Set Control rotation
|
* Set Control rotation
|
||||||
*
|
*
|
||||||
* @param float $rotation
|
* @param float $rotation Control rotation
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setRotation($rotation) {
|
public function setRotation($rotation) {
|
||||||
$this->rotation = (float)$rotation;
|
$this->rotation = (float)$rotation;
|
||||||
@ -307,7 +307,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Add a new class name
|
* Add a new class name
|
||||||
*
|
*
|
||||||
* @param string $class Class name
|
* @param string $class Class name
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addClass($class) {
|
public function addClass($class) {
|
||||||
$class = (string)$class;
|
$class = (string)$class;
|
||||||
@ -322,7 +322,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $actionName Action to trigger
|
* @param string $actionName Action to trigger
|
||||||
* @param string $eventLabel (optional) Event on which the action is triggered
|
* @param string $eventLabel (optional) Event on which the action is triggered
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addActionTriggerFeature($actionName, $eventLabel = ScriptLabel::MOUSECLICK) {
|
public function addActionTriggerFeature($actionName, $eventLabel = ScriptLabel::MOUSECLICK) {
|
||||||
if (is_object($actionName) && ($actionName instanceof ActionTrigger)) {
|
if (is_object($actionName) && ($actionName instanceof ActionTrigger)) {
|
||||||
@ -338,7 +338,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Add a new Script Feature
|
* Add a new Script Feature
|
||||||
*
|
*
|
||||||
* @param ScriptFeature $scriptFeature Script Feature
|
* @param ScriptFeature $scriptFeature Script Feature
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addScriptFeature(ScriptFeature $scriptFeature) {
|
public function addScriptFeature(ScriptFeature $scriptFeature) {
|
||||||
if (!in_array($scriptFeature, $this->scriptFeatures, true)) {
|
if (!in_array($scriptFeature, $this->scriptFeatures, true)) {
|
||||||
@ -351,7 +351,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* Add a dynamic Feature opening the current map info
|
* Add a dynamic Feature opening the current map info
|
||||||
*
|
*
|
||||||
* @param string $eventLabel (optional) Event on which the map info will be opened
|
* @param string $eventLabel (optional) Event on which the map info will be opened
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addMapInfoFeature($eventLabel = ScriptLabel::MOUSECLICK) {
|
public function addMapInfoFeature($eventLabel = ScriptLabel::MOUSECLICK) {
|
||||||
$mapInfo = new MapInfo($this, $eventLabel);
|
$mapInfo = new MapInfo($this, $eventLabel);
|
||||||
@ -364,7 +364,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $login Login of the player
|
* @param string $login Login of the player
|
||||||
* @param string $eventLabel (optional) Event on which the player profile will be opened
|
* @param string $eventLabel (optional) Event on which the player profile will be opened
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addPlayerProfileFeature($login, $eventLabel = ScriptLabel::MOUSECLICK) {
|
public function addPlayerProfileFeature($login, $eventLabel = ScriptLabel::MOUSECLICK) {
|
||||||
$playerProfile = new PlayerProfile($login, $this, $eventLabel);
|
$playerProfile = new PlayerProfile($login, $this, $eventLabel);
|
||||||
@ -378,7 +378,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* @param string $soundName UISound name
|
* @param string $soundName UISound name
|
||||||
* @param int $variant (optional) Sound variant
|
* @param int $variant (optional) Sound variant
|
||||||
* @param string $eventLabel (optional) Event on which the sound will be played
|
* @param string $eventLabel (optional) Event on which the sound will be played
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addUISoundFeature($soundName, $variant = 0, $eventLabel = ScriptLabel::MOUSECLICK) {
|
public function addUISoundFeature($soundName, $variant = 0, $eventLabel = ScriptLabel::MOUSECLICK) {
|
||||||
$uiSound = new UISound($soundName, $this, $variant, $eventLabel);
|
$uiSound = new UISound($soundName, $this, $variant, $eventLabel);
|
||||||
@ -393,7 +393,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* @param string $labelName (optional) Script label name
|
* @param string $labelName (optional) Script label name
|
||||||
* @param bool $onlyShow (optional) Whether it should only show the Control but not toggle
|
* @param bool $onlyShow (optional) Whether it should only show the Control but not toggle
|
||||||
* @param bool $onlyHide (optional) Whether it should only hide the Control but not toggle
|
* @param bool $onlyHide (optional) Whether it should only hide the Control but not toggle
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addToggleFeature(Control $toggledControl, $labelName = Scriptlabel::MOUSECLICK, $onlyShow = false, $onlyHide = false) {
|
public function addToggleFeature(Control $toggledControl, $labelName = Scriptlabel::MOUSECLICK, $onlyShow = false, $onlyHide = false) {
|
||||||
$toggle = new Toggle($this, $toggledControl, $labelName, $onlyShow, $onlyHide);
|
$toggle = new Toggle($this, $toggledControl, $labelName, $onlyShow, $onlyHide);
|
||||||
@ -407,7 +407,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* @param Control $tooltipControl Tooltip Control
|
* @param Control $tooltipControl Tooltip Control
|
||||||
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
||||||
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addTooltipFeature(Control $tooltipControl, $stayOnClick = false, $invert = false) {
|
public function addTooltipFeature(Control $tooltipControl, $stayOnClick = false, $invert = false) {
|
||||||
$tooltip = new Tooltip($this, $tooltipControl, $stayOnClick, $invert);
|
$tooltip = new Tooltip($this, $tooltipControl, $stayOnClick, $invert);
|
||||||
@ -422,7 +422,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
* @param string $text Text to display on the Tooltip Label
|
* @param string $text Text to display on the Tooltip Label
|
||||||
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
||||||
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addTooltipLabelFeature(Label $tooltipControl, $text, $stayOnClick = false, $invert = false) {
|
public function addTooltipLabelFeature(Label $tooltipControl, $text, $stayOnClick = false, $invert = false) {
|
||||||
$tooltip = new Tooltip($this, $tooltipControl, $stayOnClick, $invert, $text);
|
$tooltip = new Tooltip($this, $tooltipControl, $stayOnClick, $invert, $text);
|
||||||
@ -435,7 +435,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
*
|
*
|
||||||
* @param string $scriptText Script text
|
* @param string $scriptText Script text
|
||||||
* @param string $label (optional) Script label name
|
* @param string $label (optional) Script label name
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addScriptText($scriptText, $label = ScriptLabel::MOUSECLICK) {
|
public function addScriptText($scriptText, $label = ScriptLabel::MOUSECLICK) {
|
||||||
$customText = new ControlScript($this, $scriptText, $label);
|
$customText = new ControlScript($this, $scriptText, $label);
|
||||||
@ -446,7 +446,7 @@ abstract class Control implements Renderable, ScriptFeatureable {
|
|||||||
/**
|
/**
|
||||||
* Remove all Script Features
|
* Remove all Script Features
|
||||||
*
|
*
|
||||||
* @return \FML\Controls\Control|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeScriptFeatures() {
|
public function removeScriptFeatures() {
|
||||||
$this->scriptFeatures = array();
|
$this->scriptFeatures = array();
|
||||||
|
@ -52,7 +52,7 @@ class Entry extends Control implements NewLineable, Scriptable, Styleable, TextF
|
|||||||
* Set Entry name
|
* Set Entry name
|
||||||
*
|
*
|
||||||
* @param string $name Entry name
|
* @param string $name Entry name
|
||||||
* @return \FML\Controls\Entry
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -72,7 +72,7 @@ class Entry extends Control implements NewLineable, Scriptable, Styleable, TextF
|
|||||||
* Set default value
|
* Set default value
|
||||||
*
|
*
|
||||||
* @param string $default Default value
|
* @param string $default Default value
|
||||||
* @return \FML\Controls\Entry|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDefault($default) {
|
public function setDefault($default) {
|
||||||
$this->default = $default;
|
$this->default = $default;
|
||||||
@ -139,7 +139,7 @@ class Entry extends Control implements NewLineable, Scriptable, Styleable, TextF
|
|||||||
* Set auto completion
|
* Set auto completion
|
||||||
*
|
*
|
||||||
* @param bool $autoComplete Whether the default value should be automatically completed based on the current request parameters
|
* @param bool $autoComplete Whether the default value should be automatically completed based on the current request parameters
|
||||||
* @return \FML\Controls\Entry|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAutoComplete($autoComplete) {
|
public function setAutoComplete($autoComplete) {
|
||||||
$this->autoComplete = (bool)$autoComplete;
|
$this->autoComplete = (bool)$autoComplete;
|
||||||
@ -150,7 +150,7 @@ class Entry extends Control implements NewLineable, Scriptable, Styleable, TextF
|
|||||||
* Add a dynamic Feature submitting the Entry
|
* Add a dynamic Feature submitting the Entry
|
||||||
*
|
*
|
||||||
* @param string $url Submit url
|
* @param string $url Submit url
|
||||||
* @return \FML\Controls\Entry|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addSubmitFeature($url) {
|
public function addSubmitFeature($url) {
|
||||||
$entrySubmit = new EntrySubmit($this, $url);
|
$entrySubmit = new EntrySubmit($this, $url);
|
||||||
@ -159,7 +159,7 @@ class Entry extends Control implements NewLineable, Scriptable, Styleable, TextF
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Control::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = parent::render($domDocument);
|
$xmlElement = parent::render($domDocument);
|
||||||
|
@ -28,7 +28,7 @@ class FileEntry extends Entry {
|
|||||||
* Set the base folder
|
* Set the base folder
|
||||||
*
|
*
|
||||||
* @param string $folder Base folder
|
* @param string $folder Base folder
|
||||||
* @return \FML\Controls\FileEntry|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFolder($folder) {
|
public function setFolder($folder) {
|
||||||
$this->folder = (string)$folder;
|
$this->folder = (string)$folder;
|
||||||
@ -36,7 +36,7 @@ class FileEntry extends Entry {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Entry::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = parent::render($domDocument);
|
$xmlElement = parent::render($domDocument);
|
||||||
|
@ -82,7 +82,7 @@ class Frame extends Control implements Container {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = parent::render($domDocument);
|
$xmlElement = parent::render($domDocument);
|
||||||
|
@ -41,7 +41,7 @@ class Frame3d extends Frame implements Scriptable {
|
|||||||
* Set Style3d id
|
* Set Style3d id
|
||||||
*
|
*
|
||||||
* @param string $style3dId Style3d id
|
* @param string $style3dId Style3d id
|
||||||
* @return \FML\Controls\Frame3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStyle3dId($style3dId) {
|
public function setStyle3dId($style3dId) {
|
||||||
$this->style3dId = (string)$style3dId;
|
$this->style3dId = (string)$style3dId;
|
||||||
@ -53,7 +53,7 @@ class Frame3d extends Frame implements Scriptable {
|
|||||||
* Set Style3d
|
* Set Style3d
|
||||||
*
|
*
|
||||||
* @param Style3d $style3d Style3d object
|
* @param Style3d $style3d Style3d object
|
||||||
* @return \FML\Controls\Frame3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStyle3d(Style3d $style3d) {
|
public function setStyle3d(Style3d $style3d) {
|
||||||
$this->style3d = $style3d;
|
$this->style3d = $style3d;
|
||||||
@ -70,7 +70,7 @@ class Frame3d extends Frame implements Scriptable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Controls\Frame::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = parent::render($domDocument);
|
$xmlElement = parent::render($domDocument);
|
||||||
|
@ -26,7 +26,7 @@ class FrameInstance extends Control {
|
|||||||
*
|
*
|
||||||
* @param string $modelId (optional) Frame Model id
|
* @param string $modelId (optional) Frame Model id
|
||||||
* @param string $controlId (optional) Frame id
|
* @param string $controlId (optional) Frame id
|
||||||
* @return \FML\Controls\FrameInstance|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($modelId = null, $controlId = null) {
|
public static function create($modelId = null, $controlId = null) {
|
||||||
return new static($modelId, $controlId);
|
return new static($modelId, $controlId);
|
||||||
@ -49,7 +49,7 @@ class FrameInstance extends Control {
|
|||||||
* Set Frame Model id
|
* Set Frame Model id
|
||||||
*
|
*
|
||||||
* @param string $modelId Frame Model id
|
* @param string $modelId Frame Model id
|
||||||
* @return \FML\Controls\FrameInstance|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setModelId($modelId) {
|
public function setModelId($modelId) {
|
||||||
$this->modelId = (string)$modelId;
|
$this->modelId = (string)$modelId;
|
||||||
@ -61,7 +61,7 @@ class FrameInstance extends Control {
|
|||||||
* Set Frame Model
|
* Set Frame Model
|
||||||
*
|
*
|
||||||
* @param FrameModel $frameModel Frame Model
|
* @param FrameModel $frameModel Frame Model
|
||||||
* @return \FML\Controls\FrameInstance|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setModel(FrameModel $frameModel) {
|
public function setModel(FrameModel $frameModel) {
|
||||||
$this->model = $frameModel;
|
$this->model = $frameModel;
|
||||||
|
@ -46,7 +46,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set ratio
|
* Set ratio
|
||||||
*
|
*
|
||||||
* @param float $ratio Ratio value
|
* @param float $ratio Ratio value
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setRatio($ratio) {
|
public function setRatio($ratio) {
|
||||||
$this->ratio = (float)$ratio;
|
$this->ratio = (float)$ratio;
|
||||||
@ -57,7 +57,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set grading
|
* Set grading
|
||||||
*
|
*
|
||||||
* @param float $grading Grading value
|
* @param float $grading Grading value
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setGrading($grading) {
|
public function setGrading($grading) {
|
||||||
$this->grading = (float)$grading;
|
$this->grading = (float)$grading;
|
||||||
@ -68,7 +68,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set color
|
* Set color
|
||||||
*
|
*
|
||||||
* @param string $color Gauge color
|
* @param string $color Gauge color
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setColor($color) {
|
public function setColor($color) {
|
||||||
$this->color = (string)$color;
|
$this->color = (string)$color;
|
||||||
@ -79,7 +79,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set rotation
|
* Set rotation
|
||||||
*
|
*
|
||||||
* @param float $rotation Gauge rotation
|
* @param float $rotation Gauge rotation
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setRotation($rotation) {
|
public function setRotation($rotation) {
|
||||||
$this->rotation = (float)$rotation;
|
$this->rotation = (float)$rotation;
|
||||||
@ -90,7 +90,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set centered
|
* Set centered
|
||||||
*
|
*
|
||||||
* @param bool $centered Whether the Gauge is centered
|
* @param bool $centered Whether the Gauge is centered
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCentered($centered) {
|
public function setCentered($centered) {
|
||||||
$this->centered = ($centered ? 1 : 0);
|
$this->centered = ($centered ? 1 : 0);
|
||||||
@ -101,7 +101,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set clan
|
* Set clan
|
||||||
*
|
*
|
||||||
* @param int $clan Clan number
|
* @param int $clan Clan number
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setClan($clan) {
|
public function setClan($clan) {
|
||||||
$this->clan = (int)$clan;
|
$this->clan = (int)$clan;
|
||||||
@ -112,7 +112,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set draw background
|
* Set draw background
|
||||||
*
|
*
|
||||||
* @param bool $drawBg Whether the Gauges background should be drawn
|
* @param bool $drawBg Whether the Gauges background should be drawn
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDrawBg($drawBg) {
|
public function setDrawBg($drawBg) {
|
||||||
$this->drawBg = ($drawBg ? 1 : 0);
|
$this->drawBg = ($drawBg ? 1 : 0);
|
||||||
@ -123,7 +123,7 @@ class Gauge extends Control implements Styleable {
|
|||||||
* Set draw block background
|
* Set draw block background
|
||||||
*
|
*
|
||||||
* @param bool $drawBlockBg Whether the Gauges block background should be drawn
|
* @param bool $drawBlockBg Whether the Gauges block background should be drawn
|
||||||
* @return \FML\Controls\Gauge|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDrawBlockBg($drawBlockBg) {
|
public function setDrawBlockBg($drawBlockBg) {
|
||||||
$this->drawBlockBg = ($drawBlockBg ? 1 : 0);
|
$this->drawBlockBg = ($drawBlockBg ? 1 : 0);
|
||||||
|
@ -55,7 +55,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set text
|
* Set text
|
||||||
*
|
*
|
||||||
* @param string $text Text value
|
* @param string $text Text value
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
@ -66,7 +66,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set text id to use from Dico
|
* Set text id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $textId Text id
|
* @param string $textId Text id
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTextId($textId) {
|
public function setTextId($textId) {
|
||||||
$this->textId = (string)$textId;
|
$this->textId = (string)$textId;
|
||||||
@ -77,7 +77,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set text prefix
|
* Set text prefix
|
||||||
*
|
*
|
||||||
* @param string $textPrefix Text prefix
|
* @param string $textPrefix Text prefix
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTextPrefix($textPrefix) {
|
public function setTextPrefix($textPrefix) {
|
||||||
$this->textPrefix = (string)$textPrefix;
|
$this->textPrefix = (string)$textPrefix;
|
||||||
@ -88,7 +88,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set text emboss
|
* Set text emboss
|
||||||
*
|
*
|
||||||
* @param bool $textEmboss Whether the text should be embossed
|
* @param bool $textEmboss Whether the text should be embossed
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTextEmboss($textEmboss) {
|
public function setTextEmboss($textEmboss) {
|
||||||
$this->textEmboss = ($textEmboss ? 1 : 0);
|
$this->textEmboss = ($textEmboss ? 1 : 0);
|
||||||
@ -99,7 +99,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set translate
|
* Set translate
|
||||||
*
|
*
|
||||||
* @param bool $translate Whether the text should be translated
|
* @param bool $translate Whether the text should be translated
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTranslate($translate) {
|
public function setTranslate($translate) {
|
||||||
$this->translate = ($translate ? 1 : 0);
|
$this->translate = ($translate ? 1 : 0);
|
||||||
@ -110,7 +110,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
* Set max lines count
|
* Set max lines count
|
||||||
*
|
*
|
||||||
* @param int $maxLines Max lines count
|
* @param int $maxLines Max lines count
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setMaxLines($maxLines) {
|
public function setMaxLines($maxLines) {
|
||||||
$this->maxLines = (int)$maxLines;
|
$this->maxLines = (int)$maxLines;
|
||||||
@ -233,7 +233,7 @@ class Label extends Control implements Actionable, Linkable, NewLineable, Script
|
|||||||
*
|
*
|
||||||
* @param bool $showSeconds (optional) Whether the seconds should be shown
|
* @param bool $showSeconds (optional) Whether the seconds should be shown
|
||||||
* @param bool $showFullDate (optional) Whether the date should be shown
|
* @param bool $showFullDate (optional) Whether the date should be shown
|
||||||
* @return \FML\Controls\Label|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addClockFeature($showSeconds = true, $showFullDate = false) {
|
public function addClockFeature($showSeconds = true, $showFullDate = false) {
|
||||||
$clock = new Clock($this, $showSeconds, $showFullDate);
|
$clock = new Clock($this, $showSeconds, $showFullDate);
|
||||||
|
@ -52,7 +52,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set image url
|
* Set image url
|
||||||
*
|
*
|
||||||
* @param string $image Image url
|
* @param string $image Image url
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setImage($image) {
|
public function setImage($image) {
|
||||||
$this->image = (string)$image;
|
$this->image = (string)$image;
|
||||||
@ -63,7 +63,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set image id to use from Dico
|
* Set image id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $imageId Image id
|
* @param string $imageId Image id
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setImageId($imageId) {
|
public function setImageId($imageId) {
|
||||||
$this->imageId = (string)$imageId;
|
$this->imageId = (string)$imageId;
|
||||||
@ -74,7 +74,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set focus image url
|
* Set focus image url
|
||||||
*
|
*
|
||||||
* @param string $imageFocus Focus image url
|
* @param string $imageFocus Focus image url
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setImageFocus($imageFocus) {
|
public function setImageFocus($imageFocus) {
|
||||||
$this->imageFocus = (string)$imageFocus;
|
$this->imageFocus = (string)$imageFocus;
|
||||||
@ -85,7 +85,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set focus image id to use from Dico
|
* Set focus image id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $imageFocusId Focus image id
|
* @param string $imageFocusId Focus image id
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setImageFocusId($imageFocusId) {
|
public function setImageFocusId($imageFocusId) {
|
||||||
$this->imageFocusId = (string)$imageFocusId;
|
$this->imageFocusId = (string)$imageFocusId;
|
||||||
@ -96,7 +96,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set colorization
|
* Set colorization
|
||||||
*
|
*
|
||||||
* @param string $colorize Colorize value
|
* @param string $colorize Colorize value
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setColorize($colorize) {
|
public function setColorize($colorize) {
|
||||||
$this->colorize = (string)$colorize;
|
$this->colorize = (string)$colorize;
|
||||||
@ -107,7 +107,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Set modulization
|
* Set modulization
|
||||||
*
|
*
|
||||||
* @param string $modulizeColor Modulize value
|
* @param string $modulizeColor Modulize value
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setModulizeColor($modulizeColor) {
|
public function setModulizeColor($modulizeColor) {
|
||||||
$this->modulizeColor = (string)$modulizeColor;
|
$this->modulizeColor = (string)$modulizeColor;
|
||||||
@ -118,7 +118,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Disable the automatic image scaling
|
* Disable the automatic image scaling
|
||||||
*
|
*
|
||||||
* @param bool $autoScale Whether the image should scale automatically
|
* @param bool $autoScale Whether the image should scale automatically
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAutoScale($autoScale) {
|
public function setAutoScale($autoScale) {
|
||||||
$this->autoScale = ($autoScale ? 1 : 0);
|
$this->autoScale = ($autoScale ? 1 : 0);
|
||||||
@ -225,7 +225,7 @@ class Quad extends Control implements Actionable, BgColorable, Linkable, Scripta
|
|||||||
* Apply the given CheckBox Design
|
* Apply the given CheckBox Design
|
||||||
*
|
*
|
||||||
* @param CheckBoxDesign $checkBoxDesign CheckBox Design
|
* @param CheckBoxDesign $checkBoxDesign CheckBox Design
|
||||||
* @return \FML\Controls\Quad|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function applyCheckBoxDesign(CheckBoxDesign $checkBoxDesign) {
|
public function applyCheckBoxDesign(CheckBoxDesign $checkBoxDesign) {
|
||||||
$checkBoxDesign->applyToQuad($this);
|
$checkBoxDesign->applyToQuad($this);
|
||||||
|
@ -27,7 +27,7 @@ class CustomUI {
|
|||||||
/**
|
/**
|
||||||
* Create a new CustomUI object
|
* Create a new CustomUI object
|
||||||
*
|
*
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -37,7 +37,7 @@ class CustomUI {
|
|||||||
* Set XML encoding
|
* Set XML encoding
|
||||||
*
|
*
|
||||||
* @param string $encoding XML encoding
|
* @param string $encoding XML encoding
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setXMLEncoding($encoding) {
|
public function setXMLEncoding($encoding) {
|
||||||
$this->encoding = (string)$encoding;
|
$this->encoding = (string)$encoding;
|
||||||
@ -48,7 +48,7 @@ class CustomUI {
|
|||||||
* Set showing of notices
|
* Set showing of notices
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether notices should be shown
|
* @param bool $visible Whether notices should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setNoticeVisible($visible) {
|
public function setNoticeVisible($visible) {
|
||||||
$this->noticeVisible = $visible;
|
$this->noticeVisible = $visible;
|
||||||
@ -59,7 +59,7 @@ class CustomUI {
|
|||||||
* Set showing of the challenge info
|
* Set showing of the challenge info
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the challenge info should be shown
|
* @param bool $visible Whether the challenge info should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setChallengeInfoVisible($visible) {
|
public function setChallengeInfoVisible($visible) {
|
||||||
$this->challengeInfoVisible = $visible;
|
$this->challengeInfoVisible = $visible;
|
||||||
@ -70,7 +70,7 @@ class CustomUI {
|
|||||||
* Set showing of the net infos
|
* Set showing of the net infos
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the net infos should be shown
|
* @param bool $visible Whether the net infos should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setNetInfosVisible($visible) {
|
public function setNetInfosVisible($visible) {
|
||||||
$this->netInfosVisible = $visible;
|
$this->netInfosVisible = $visible;
|
||||||
@ -81,7 +81,7 @@ class CustomUI {
|
|||||||
* Set showing of the chat
|
* Set showing of the chat
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the chat should be shown
|
* @param bool $visible Whether the chat should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setChatVisible($visible) {
|
public function setChatVisible($visible) {
|
||||||
$this->chatVisible = $visible;
|
$this->chatVisible = $visible;
|
||||||
@ -92,7 +92,7 @@ class CustomUI {
|
|||||||
* Set showing of the checkpoint list
|
* Set showing of the checkpoint list
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the checkpoint should be shown
|
* @param bool $visible Whether the checkpoint should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCheckpointListVisible($visible) {
|
public function setCheckpointListVisible($visible) {
|
||||||
$this->checkpointListVisible = $visible;
|
$this->checkpointListVisible = $visible;
|
||||||
@ -103,7 +103,7 @@ class CustomUI {
|
|||||||
* Set showing of round scores
|
* Set showing of round scores
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the round scores should be shown
|
* @param bool $visible Whether the round scores should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setRoundScoresVisible($visible) {
|
public function setRoundScoresVisible($visible) {
|
||||||
$this->roundScoresVisible = $visible;
|
$this->roundScoresVisible = $visible;
|
||||||
@ -114,7 +114,7 @@ class CustomUI {
|
|||||||
* Set showing of the scoretable
|
* Set showing of the scoretable
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the scoretable should be shown
|
* @param bool $visible Whether the scoretable should be shown
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setScoretableVisible($visible) {
|
public function setScoretableVisible($visible) {
|
||||||
$this->scoretableVisible = $visible;
|
$this->scoretableVisible = $visible;
|
||||||
@ -125,7 +125,7 @@ class CustomUI {
|
|||||||
* Set global showing
|
* Set global showing
|
||||||
*
|
*
|
||||||
* @param bool $visible Whether the UI should be disabled completely
|
* @param bool $visible Whether the UI should be disabled completely
|
||||||
* @return \FML\CustomUI|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setGlobalVisible($visible) {
|
public function setGlobalVisible($visible) {
|
||||||
$this->globalVisible = $visible;
|
$this->globalVisible = $visible;
|
||||||
|
@ -159,7 +159,7 @@ class Dico {
|
|||||||
/**
|
/**
|
||||||
* Create a new Dictionary object
|
* Create a new Dictionary object
|
||||||
*
|
*
|
||||||
* @return \FML\Elements\Dico|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -171,7 +171,7 @@ class Dico {
|
|||||||
* @param string $language Language id
|
* @param string $language Language id
|
||||||
* @param string $entryId Entry id
|
* @param string $entryId Entry id
|
||||||
* @param string $entryValue Translated entry value
|
* @param string $entryValue Translated entry value
|
||||||
* @return \FML\Elements\Dico|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEntry($language, $entryId, $entryValue) {
|
public function setEntry($language, $entryId, $entryValue) {
|
||||||
$language = (string)$language;
|
$language = (string)$language;
|
||||||
@ -195,7 +195,7 @@ class Dico {
|
|||||||
*
|
*
|
||||||
* @param string $entryId Entry id that should be removed
|
* @param string $entryId Entry id that should be removed
|
||||||
* @param string $language (optional) Only remove entries of the given language
|
* @param string $language (optional) Only remove entries of the given language
|
||||||
* @return \FML\Elements\Dico|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeEntry($entryId, $language = null) {
|
public function removeEntry($entryId, $language = null) {
|
||||||
$entryId = (string)$entryId;
|
$entryId = (string)$entryId;
|
||||||
@ -219,7 +219,7 @@ class Dico {
|
|||||||
*
|
*
|
||||||
* @param string $language Language which entries should be removed
|
* @param string $language Language which entries should be removed
|
||||||
* @param string $entryId (optional) Only remove the given entry id
|
* @param string $entryId (optional) Only remove the given entry id
|
||||||
* @return \FML\Elements\Dico|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeLanguage($language, $entryId = null) {
|
public function removeLanguage($language, $entryId = null) {
|
||||||
$language = (string)$language;
|
$language = (string)$language;
|
||||||
@ -237,7 +237,7 @@ class Dico {
|
|||||||
/**
|
/**
|
||||||
* Remove all entries from the Dictionary
|
* Remove all entries from the Dictionary
|
||||||
*
|
*
|
||||||
* @return \FML\Elements\Dico|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeEntries() {
|
public function removeEntries() {
|
||||||
$this->entries = array();
|
$this->entries = array();
|
||||||
|
@ -29,7 +29,7 @@ class Format implements BgColorable, Renderable, Styleable, TextFormatable {
|
|||||||
/**
|
/**
|
||||||
* Create a new Format Element
|
* Create a new Format Element
|
||||||
*
|
*
|
||||||
* @return \FML\Elements\Format|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -84,7 +84,7 @@ class Format implements BgColorable, Renderable, Styleable, TextFormatable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$formatXmlElement = $domDocument->createElement($this->tagName);
|
$formatXmlElement = $domDocument->createElement($this->tagName);
|
||||||
|
@ -28,7 +28,7 @@ class FrameModel implements Container, Renderable {
|
|||||||
* Set Model id
|
* Set Model id
|
||||||
*
|
*
|
||||||
* @param string $modelId Model id
|
* @param string $modelId Model id
|
||||||
* @return \FML\Elements\FrameModel|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setId($modelId) {
|
public function setId($modelId) {
|
||||||
$this->modelId = (string)$modelId;
|
$this->modelId = (string)$modelId;
|
||||||
@ -51,7 +51,7 @@ class FrameModel implements Container, Renderable {
|
|||||||
*/
|
*/
|
||||||
public function checkId() {
|
public function checkId() {
|
||||||
if (!$this->modelId) {
|
if (!$this->modelId) {
|
||||||
$this->setId(new UniqueID());
|
$this->setId(UniqueID::create());
|
||||||
}
|
}
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
@ -22,7 +22,7 @@ class Including implements Renderable {
|
|||||||
* Create a new Include object
|
* Create a new Include object
|
||||||
*
|
*
|
||||||
* @param string $url (optional) Include url
|
* @param string $url (optional) Include url
|
||||||
* @return \FML\Elements\Including|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($url = null) {
|
public static function create($url = null) {
|
||||||
return new static($url);
|
return new static($url);
|
||||||
@ -43,7 +43,7 @@ class Including implements Renderable {
|
|||||||
* Set url
|
* Set url
|
||||||
*
|
*
|
||||||
* @param string $url Include url
|
* @param string $url Include url
|
||||||
* @return \FML\Elements\Including|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -51,7 +51,7 @@ class Including implements Renderable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = $domDocument->createElement($this->tagName);
|
||||||
|
@ -22,7 +22,7 @@ class Music implements Renderable {
|
|||||||
* Create a new Music object
|
* Create a new Music object
|
||||||
*
|
*
|
||||||
* @param string $data (optional) Media url
|
* @param string $data (optional) Media url
|
||||||
* @return \FML\Elements\Music|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($data = null) {
|
public static function create($data = null) {
|
||||||
return new static($data);
|
return new static($data);
|
||||||
@ -43,7 +43,7 @@ class Music implements Renderable {
|
|||||||
* Set data url
|
* Set data url
|
||||||
*
|
*
|
||||||
* @param string $data Data url
|
* @param string $data Data url
|
||||||
* @return \FML\Elements\Music|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setData($data) {
|
public function setData($data) {
|
||||||
$this->data = (string)$data;
|
$this->data = (string)$data;
|
||||||
@ -51,7 +51,7 @@ class Music implements Renderable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see \FML\Renderable::render()
|
* @see \FML\Types\Renderable::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = $domDocument->createElement($this->tagName);
|
||||||
|
@ -22,7 +22,7 @@ class SimpleScript implements Renderable {
|
|||||||
* Create a new SimpleScript object
|
* Create a new SimpleScript object
|
||||||
*
|
*
|
||||||
* @param string $text (optional) Script text
|
* @param string $text (optional) Script text
|
||||||
* @return \FML\Elements\SimpleScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($text = null) {
|
public static function create($text = null) {
|
||||||
return new static($text);
|
return new static($text);
|
||||||
@ -43,7 +43,7 @@ class SimpleScript implements Renderable {
|
|||||||
* Set script text
|
* Set script text
|
||||||
*
|
*
|
||||||
* @param string $text Complete script text
|
* @param string $text Complete script text
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
|
@ -39,7 +39,7 @@ class ManiaCode {
|
|||||||
/**
|
/**
|
||||||
* Create a new ManiaCode object
|
* Create a new ManiaCode object
|
||||||
*
|
*
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -49,7 +49,7 @@ class ManiaCode {
|
|||||||
* Set XML encoding
|
* Set XML encoding
|
||||||
*
|
*
|
||||||
* @param string $encoding XML encoding
|
* @param string $encoding XML encoding
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setXmlEncoding($encoding) {
|
public function setXmlEncoding($encoding) {
|
||||||
$this->encoding = (string)$encoding;
|
$this->encoding = (string)$encoding;
|
||||||
@ -60,7 +60,7 @@ class ManiaCode {
|
|||||||
* Disable the showing of the confirmation at the end of the ManiaCode
|
* Disable the showing of the confirmation at the end of the ManiaCode
|
||||||
*
|
*
|
||||||
* @param bool $disable Whether the confirmation should be shown
|
* @param bool $disable Whether the confirmation should be shown
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function disableConfirmation($disable) {
|
public function disableConfirmation($disable) {
|
||||||
$this->noConfirmation = ($disable ? 1 : 0);
|
$this->noConfirmation = ($disable ? 1 : 0);
|
||||||
@ -71,7 +71,7 @@ class ManiaCode {
|
|||||||
* Show a message
|
* Show a message
|
||||||
*
|
*
|
||||||
* @param string $message Message text
|
* @param string $message Message text
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addShowMessage($message) {
|
public function addShowMessage($message) {
|
||||||
$messageElement = new ShowMessage($message);
|
$messageElement = new ShowMessage($message);
|
||||||
@ -85,7 +85,7 @@ class ManiaCode {
|
|||||||
* @param string $name Macroblock name
|
* @param string $name Macroblock name
|
||||||
* @param string $file Macroblock file
|
* @param string $file Macroblock file
|
||||||
* @param string $url Macroblock url
|
* @param string $url Macroblock url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallMacroblock($name, $file, $url) {
|
public function addInstallMacroblock($name, $file, $url) {
|
||||||
$macroblockElement = new InstallMacroblock($name, $file, $url);
|
$macroblockElement = new InstallMacroblock($name, $file, $url);
|
||||||
@ -98,7 +98,7 @@ class ManiaCode {
|
|||||||
*
|
*
|
||||||
* @param string $name Map name
|
* @param string $name Map name
|
||||||
* @param string $url Map url
|
* @param string $url Map url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallMap($name, $url) {
|
public function addInstallMap($name, $url) {
|
||||||
$mapElement = new InstallMap($name, $url);
|
$mapElement = new InstallMap($name, $url);
|
||||||
@ -111,7 +111,7 @@ class ManiaCode {
|
|||||||
*
|
*
|
||||||
* @param string $name Map name
|
* @param string $name Map name
|
||||||
* @param string $url Map url
|
* @param string $url Map url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addPlayMap($name, $url) {
|
public function addPlayMap($name, $url) {
|
||||||
$mapElement = new PlayMap($name, $url);
|
$mapElement = new PlayMap($name, $url);
|
||||||
@ -124,7 +124,7 @@ class ManiaCode {
|
|||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallReplay($name, $url) {
|
public function addInstallReplay($name, $url) {
|
||||||
$replayElement = new InstallReplay($name, $url);
|
$replayElement = new InstallReplay($name, $url);
|
||||||
@ -137,7 +137,7 @@ class ManiaCode {
|
|||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addViewReplay($name, $url) {
|
public function addViewReplay($name, $url) {
|
||||||
$replayElement = new ViewReplay($name, $url);
|
$replayElement = new ViewReplay($name, $url);
|
||||||
@ -150,7 +150,7 @@ class ManiaCode {
|
|||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addPlayReplay($name, $url) {
|
public function addPlayReplay($name, $url) {
|
||||||
$replayElement = new PlayReplay($name, $url);
|
$replayElement = new PlayReplay($name, $url);
|
||||||
@ -164,7 +164,7 @@ class ManiaCode {
|
|||||||
* @param string $name Skin name
|
* @param string $name Skin name
|
||||||
* @param string $file Skin file
|
* @param string $file Skin file
|
||||||
* @param string $url Skin url
|
* @param string $url Skin url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallSkin($name, $file, $url) {
|
public function addInstallSkin($name, $file, $url) {
|
||||||
$skinElement = new InstallSkin($name, $file, $url);
|
$skinElement = new InstallSkin($name, $file, $url);
|
||||||
@ -178,7 +178,7 @@ class ManiaCode {
|
|||||||
* @param string $name Skin name
|
* @param string $name Skin name
|
||||||
* @param string $file Skin file
|
* @param string $file Skin file
|
||||||
* @param string $url Skin url
|
* @param string $url Skin url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addGetSkin($name, $file, $url) {
|
public function addGetSkin($name, $file, $url) {
|
||||||
$skinElement = new GetSkin($name, $file, $url);
|
$skinElement = new GetSkin($name, $file, $url);
|
||||||
@ -190,7 +190,7 @@ class ManiaCode {
|
|||||||
* Add a buddy
|
* Add a buddy
|
||||||
*
|
*
|
||||||
* @param string $login Buddy login
|
* @param string $login Buddy login
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addAddBuddy($login) {
|
public function addAddBuddy($login) {
|
||||||
$buddyElement = new AddBuddy($login);
|
$buddyElement = new AddBuddy($login);
|
||||||
@ -202,7 +202,7 @@ class ManiaCode {
|
|||||||
* Go to a link
|
* Go to a link
|
||||||
*
|
*
|
||||||
* @param string $link Goto link
|
* @param string $link Goto link
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addGoto($link) {
|
public function addGoto($link) {
|
||||||
$gotoElement = new Go_To($link);
|
$gotoElement = new Go_To($link);
|
||||||
@ -214,7 +214,7 @@ class ManiaCode {
|
|||||||
* Join a server
|
* Join a server
|
||||||
*
|
*
|
||||||
* @param string $login Server login
|
* @param string $login Server login
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addJoinServer($login) {
|
public function addJoinServer($login) {
|
||||||
$serverElement = new JoinServer($login);
|
$serverElement = new JoinServer($login);
|
||||||
@ -226,7 +226,7 @@ class ManiaCode {
|
|||||||
* Add a server as favorite
|
* Add a server as favorite
|
||||||
*
|
*
|
||||||
* @param string $login Server login
|
* @param string $login Server login
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addAddFavorite($login) {
|
public function addAddFavorite($login) {
|
||||||
$favoriteElement = new AddFavorite($login);
|
$favoriteElement = new AddFavorite($login);
|
||||||
@ -240,7 +240,7 @@ class ManiaCode {
|
|||||||
* @param string $name Script name
|
* @param string $name Script name
|
||||||
* @param string $file Script file
|
* @param string $file Script file
|
||||||
* @param string $url Script url
|
* @param string $url Script url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallScript($name, $file, $url) {
|
public function addInstallScript($name, $file, $url) {
|
||||||
$scriptElement = new InstallScript($name, $file, $url);
|
$scriptElement = new InstallScript($name, $file, $url);
|
||||||
@ -254,7 +254,7 @@ class ManiaCode {
|
|||||||
* @param string $name Pack name
|
* @param string $name Pack name
|
||||||
* @param string $file Pack file
|
* @param string $file Pack file
|
||||||
* @param string $url Pack url
|
* @param string $url Pack url
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addInstallPack($name, $file, $url) {
|
public function addInstallPack($name, $file, $url) {
|
||||||
$packElement = new InstallPack($name, $file, $url);
|
$packElement = new InstallPack($name, $file, $url);
|
||||||
@ -266,7 +266,7 @@ class ManiaCode {
|
|||||||
* Add a ManiaCode element
|
* Add a ManiaCode element
|
||||||
*
|
*
|
||||||
* @param Element $element Element to add
|
* @param Element $element Element to add
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addElement(Element $element) {
|
public function addElement(Element $element) {
|
||||||
array_push($this->elements, $element);
|
array_push($this->elements, $element);
|
||||||
@ -276,7 +276,7 @@ class ManiaCode {
|
|||||||
/**
|
/**
|
||||||
* Remove all elements from the ManiaCode
|
* Remove all elements from the ManiaCode
|
||||||
*
|
*
|
||||||
* @return \FML\ManiaCode|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeElements() {
|
public function removeElements() {
|
||||||
$this->elements = array();
|
$this->elements = array();
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class AddBuddy implements Element {
|
class AddBuddy extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -20,7 +20,7 @@ class AddBuddy implements Element {
|
|||||||
* Create a new AddBuddy Element
|
* Create a new AddBuddy Element
|
||||||
*
|
*
|
||||||
* @param string $login (optional) Buddy login
|
* @param string $login (optional) Buddy login
|
||||||
* @return \FML\ManiaCode\AddBuddy|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($login = null) {
|
public static function create($login = null) {
|
||||||
return new static($login);
|
return new static($login);
|
||||||
@ -41,7 +41,7 @@ class AddBuddy implements Element {
|
|||||||
* Set the buddy login
|
* Set the buddy login
|
||||||
*
|
*
|
||||||
* @param string $login Buddy login
|
* @param string $login Buddy login
|
||||||
* @return \FML\ManiaCode\AddBuddy|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLogin($login) {
|
public function setLogin($login) {
|
||||||
$this->login = (string)$login;
|
$this->login = (string)$login;
|
||||||
@ -52,7 +52,7 @@ class AddBuddy implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$loginElement = $domDocument->createElement('login', $this->login);
|
$loginElement = $domDocument->createElement('login', $this->login);
|
||||||
$xmlElement->appendChild($loginElement);
|
$xmlElement->appendChild($loginElement);
|
||||||
return $xmlElement;
|
return $xmlElement;
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class AddFavorite implements Element {
|
class AddFavorite extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class AddFavorite implements Element {
|
|||||||
* Create a new AddFavorite object
|
* Create a new AddFavorite object
|
||||||
*
|
*
|
||||||
* @param string $login (optional) Server login
|
* @param string $login (optional) Server login
|
||||||
* @return \FML\ManiaCode\AddFavorite|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($login = null) {
|
public static function create($login = null) {
|
||||||
return new static($login);
|
return new static($login);
|
||||||
@ -43,7 +43,7 @@ class AddFavorite implements Element {
|
|||||||
* Set the server login
|
* Set the server login
|
||||||
*
|
*
|
||||||
* @param string $login Server login
|
* @param string $login Server login
|
||||||
* @return \FML\ManiaCode\AddFavorite|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLogin($login) {
|
public function setLogin($login) {
|
||||||
$this->login = (string)$login;
|
$this->login = (string)$login;
|
||||||
@ -57,7 +57,7 @@ class AddFavorite implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $serverIp Server ip
|
* @param string $serverIp Server ip
|
||||||
* @param int $serverPort Server port
|
* @param int $serverPort Server port
|
||||||
* @return \FML\ManiaCode\AddFavorite|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setIp($serverIp, $serverPort) {
|
public function setIp($serverIp, $serverPort) {
|
||||||
$this->serverIp = (string)$serverIp;
|
$this->serverIp = (string)$serverIp;
|
||||||
@ -70,7 +70,7 @@ class AddFavorite implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
if (is_null($this->serverIp)) {
|
if (is_null($this->serverIp)) {
|
||||||
$loginElement = $domDocument->createElement('login', $this->login);
|
$loginElement = $domDocument->createElement('login', $this->login);
|
||||||
$xmlElement->appendChild($loginElement);
|
$xmlElement->appendChild($loginElement);
|
||||||
|
@ -9,7 +9,11 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
interface Element {
|
abstract class Element {
|
||||||
|
/*
|
||||||
|
* Protected properties
|
||||||
|
*/
|
||||||
|
protected $tagName = 'element';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Render the ManiaCode Element
|
* Render the ManiaCode Element
|
||||||
@ -17,5 +21,8 @@ interface Element {
|
|||||||
* @param \DOMDocument $domDocument The DOMDocument for which the Element should be rendered
|
* @param \DOMDocument $domDocument The DOMDocument for which the Element should be rendered
|
||||||
* @return \DOMElement
|
* @return \DOMElement
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument);
|
public function render(\DOMDocument $domDocument) {
|
||||||
|
$xmlElement = $domDocument->createElement($this->tagName);
|
||||||
|
return $xmlElement;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class GetSkin implements Element {
|
class GetSkin extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -24,7 +24,7 @@ class GetSkin implements Element {
|
|||||||
* @param string $name (optional) Skin name
|
* @param string $name (optional) Skin name
|
||||||
* @param string $file (optional) Skin file
|
* @param string $file (optional) Skin file
|
||||||
* @param string $url (optional) Skin url
|
* @param string $url (optional) Skin url
|
||||||
* @return \FML\ManiaCode\GetSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $file = null, $url = null) {
|
public static function create($name = null, $file = null, $url = null) {
|
||||||
return new static($name, $file, $url);
|
return new static($name, $file, $url);
|
||||||
@ -53,7 +53,7 @@ class GetSkin implements Element {
|
|||||||
* Set the name of the skin
|
* Set the name of the skin
|
||||||
*
|
*
|
||||||
* @param string $name Skin name
|
* @param string $name Skin name
|
||||||
* @return \FML\ManiaCode\GetSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -64,7 +64,7 @@ class GetSkin implements Element {
|
|||||||
* Set the file of the skin
|
* Set the file of the skin
|
||||||
*
|
*
|
||||||
* @param string $file Skin file
|
* @param string $file Skin file
|
||||||
* @return \FML\ManiaCode\GetSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -75,7 +75,7 @@ class GetSkin implements Element {
|
|||||||
* Set the url of the skin
|
* Set the url of the skin
|
||||||
*
|
*
|
||||||
* @param string $url Skin url
|
* @param string $url Skin url
|
||||||
* @return \FML\ManiaCode\GetSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -86,7 +86,7 @@ class GetSkin implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$fileElement = $domDocument->createElement('file', $this->file);
|
$fileElement = $domDocument->createElement('file', $this->file);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class Go_To implements Element {
|
class Go_To extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -20,7 +20,7 @@ class Go_To implements Element {
|
|||||||
* Create a new Go_To object
|
* Create a new Go_To object
|
||||||
*
|
*
|
||||||
* @param string $link (optional) Goto link
|
* @param string $link (optional) Goto link
|
||||||
* @return \FML\ManiaCode\Go_To|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($link = null) {
|
public static function create($link = null) {
|
||||||
return new static($link);
|
return new static($link);
|
||||||
@ -41,7 +41,7 @@ class Go_To implements Element {
|
|||||||
* Set link
|
* Set link
|
||||||
*
|
*
|
||||||
* @param string $link Goto link
|
* @param string $link Goto link
|
||||||
* @return \FML\ManiaCode\Go_To|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLink($link) {
|
public function setLink($link) {
|
||||||
$this->link = (string)$link;
|
$this->link = (string)$link;
|
||||||
@ -52,7 +52,7 @@ class Go_To implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$linkElement = $domDocument->createElement('link', $this->link);
|
$linkElement = $domDocument->createElement('link', $this->link);
|
||||||
$xmlElement->appendChild($linkElement);
|
$xmlElement->appendChild($linkElement);
|
||||||
return $xmlElement;
|
return $xmlElement;
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallMacroblock implements Element {
|
class InstallMacroblock extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -23,7 +23,7 @@ class InstallMacroblock implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Macroblock name
|
* @param string $name (optional) Macroblock name
|
||||||
* @param string $url (optional) Macroblock url
|
* @param string $url (optional) Macroblock url
|
||||||
* @return \FML\ManiaCode\InstallMacroblock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -52,7 +52,7 @@ class InstallMacroblock implements Element {
|
|||||||
* Set the name of the macroblock
|
* Set the name of the macroblock
|
||||||
*
|
*
|
||||||
* @param string $name Macroblock name
|
* @param string $name Macroblock name
|
||||||
* @return \FML\ManiaCode\InstallMacroblock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -63,7 +63,7 @@ class InstallMacroblock implements Element {
|
|||||||
* Set the file of the macroblock
|
* Set the file of the macroblock
|
||||||
*
|
*
|
||||||
* @param string $file Macroblock file
|
* @param string $file Macroblock file
|
||||||
* @return \FML\ManiaCode\InstallMacroblock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -74,7 +74,7 @@ class InstallMacroblock implements Element {
|
|||||||
* Set the url of the macroblock
|
* Set the url of the macroblock
|
||||||
*
|
*
|
||||||
* @param string $url Macroblock url
|
* @param string $url Macroblock url
|
||||||
* @return \FML\ManiaCode\InstallMacroblock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -85,7 +85,7 @@ class InstallMacroblock implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$fileElement = $domDocument->createElement('file', $this->file);
|
$fileElement = $domDocument->createElement('file', $this->file);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallMap implements Element {
|
class InstallMap extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class InstallMap implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Map name
|
* @param string $name (optional) Map name
|
||||||
* @param string $url (optional) Map url
|
* @param string $url (optional) Map url
|
||||||
* @return \FML\ManiaCode\InstallMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -47,7 +47,7 @@ class InstallMap implements Element {
|
|||||||
* Set the name of the map
|
* Set the name of the map
|
||||||
*
|
*
|
||||||
* @param string $name Map name
|
* @param string $name Map name
|
||||||
* @return \FML\ManiaCode\InstallMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -58,7 +58,7 @@ class InstallMap implements Element {
|
|||||||
* Set the url of the map
|
* Set the url of the map
|
||||||
*
|
*
|
||||||
* @param string $url Map url
|
* @param string $url Map url
|
||||||
* @return \FML\ManiaCode\InstallMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -69,7 +69,7 @@ class InstallMap implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$urlElement = $domDocument->createElement('url', $this->url);
|
$urlElement = $domDocument->createElement('url', $this->url);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallPack implements Element {
|
class InstallPack extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -24,7 +24,7 @@ class InstallPack implements Element {
|
|||||||
* @param string $name (optional) Pack name
|
* @param string $name (optional) Pack name
|
||||||
* @param string $file (optional) Pack file
|
* @param string $file (optional) Pack file
|
||||||
* @param string $url (optional) Pack url
|
* @param string $url (optional) Pack url
|
||||||
* @return \FML\ManiaCode\InstallPack|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $file = null, $url = null) {
|
public static function create($name = null, $file = null, $url = null) {
|
||||||
return new static($name, $file, $url);
|
return new static($name, $file, $url);
|
||||||
@ -53,7 +53,7 @@ class InstallPack implements Element {
|
|||||||
* Set the name of the pack
|
* Set the name of the pack
|
||||||
*
|
*
|
||||||
* @param string $name Pack name
|
* @param string $name Pack name
|
||||||
* @return \FML\ManiaCode\InstallPack|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -64,7 +64,7 @@ class InstallPack implements Element {
|
|||||||
* Set the file of the pack
|
* Set the file of the pack
|
||||||
*
|
*
|
||||||
* @param string $file Pack file
|
* @param string $file Pack file
|
||||||
* @return \FML\ManiaCode\InstallPack|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -75,7 +75,7 @@ class InstallPack implements Element {
|
|||||||
* Set the url of the pack
|
* Set the url of the pack
|
||||||
*
|
*
|
||||||
* @param string $url Pack url
|
* @param string $url Pack url
|
||||||
* @return \FML\ManiaCode\InstallPack|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -86,7 +86,7 @@ class InstallPack implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$fileElement = $domDocument->createElement('file', $this->file);
|
$fileElement = $domDocument->createElement('file', $this->file);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallReplay implements Element {
|
class InstallReplay extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class InstallReplay implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Replay name
|
* @param string $name (optional) Replay name
|
||||||
* @param string $url (optional) Replay url
|
* @param string $url (optional) Replay url
|
||||||
* @return \FML\ManiaCode\InstallReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -47,7 +47,7 @@ class InstallReplay implements Element {
|
|||||||
* Set the name of the replay
|
* Set the name of the replay
|
||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @return \FML\ManiaCode\InstallReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -58,7 +58,7 @@ class InstallReplay implements Element {
|
|||||||
* Set the url of the replay
|
* Set the url of the replay
|
||||||
*
|
*
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode\InstallReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -69,7 +69,7 @@ class InstallReplay implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$urlElement = $domDocument->createElement('url', $this->url);
|
$urlElement = $domDocument->createElement('url', $this->url);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallScript implements Element {
|
class InstallScript extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -24,7 +24,7 @@ class InstallScript implements Element {
|
|||||||
* @param string $name (optional) Script name
|
* @param string $name (optional) Script name
|
||||||
* @param string $file (optional) Script file
|
* @param string $file (optional) Script file
|
||||||
* @param string $url (optional) Script url
|
* @param string $url (optional) Script url
|
||||||
* @return \FML\ManiaCode\InstallScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $file = null, $url = null) {
|
public static function create($name = null, $file = null, $url = null) {
|
||||||
return new static($name, $file, $url);
|
return new static($name, $file, $url);
|
||||||
@ -53,7 +53,7 @@ class InstallScript implements Element {
|
|||||||
* Set the name of the script
|
* Set the name of the script
|
||||||
*
|
*
|
||||||
* @param string $name Script name
|
* @param string $name Script name
|
||||||
* @return \FML\ManiaCode\InstallScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -64,7 +64,7 @@ class InstallScript implements Element {
|
|||||||
* Set the file of the script
|
* Set the file of the script
|
||||||
*
|
*
|
||||||
* @param string $file Script file
|
* @param string $file Script file
|
||||||
* @return \FML\ManiaCode\InstallScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -75,7 +75,7 @@ class InstallScript implements Element {
|
|||||||
* Set the url of the script
|
* Set the url of the script
|
||||||
*
|
*
|
||||||
* @param string $url Script url
|
* @param string $url Script url
|
||||||
* @return \FML\ManiaCode\InstallScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -86,7 +86,7 @@ class InstallScript implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$fileElement = $domDocument->createElement('file', $this->file);
|
$fileElement = $domDocument->createElement('file', $this->file);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class InstallSkin implements Element {
|
class InstallSkin extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -24,7 +24,7 @@ class InstallSkin implements Element {
|
|||||||
* @param string $name (optional) Skin name
|
* @param string $name (optional) Skin name
|
||||||
* @param string $file (optional) Skin file
|
* @param string $file (optional) Skin file
|
||||||
* @param string $url (optional) Skin url
|
* @param string $url (optional) Skin url
|
||||||
* @return \FML\ManiaCode\InstallSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $file = null, $url = null) {
|
public static function create($name = null, $file = null, $url = null) {
|
||||||
return new static($name, $file, $url);
|
return new static($name, $file, $url);
|
||||||
@ -53,7 +53,7 @@ class InstallSkin implements Element {
|
|||||||
* Set the name of the skin
|
* Set the name of the skin
|
||||||
*
|
*
|
||||||
* @param string $name Skin name
|
* @param string $name Skin name
|
||||||
* @return \FML\ManiaCode\InstallSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -64,7 +64,7 @@ class InstallSkin implements Element {
|
|||||||
* Set the file of the skin
|
* Set the file of the skin
|
||||||
*
|
*
|
||||||
* @param string $file Skin file
|
* @param string $file Skin file
|
||||||
* @return \FML\ManiaCode\InstallSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -75,7 +75,7 @@ class InstallSkin implements Element {
|
|||||||
* Set the url of the skin
|
* Set the url of the skin
|
||||||
*
|
*
|
||||||
* @param string $url Skin url
|
* @param string $url Skin url
|
||||||
* @return \FML\ManiaCode\InstallSkin|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -86,7 +86,7 @@ class InstallSkin implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$fileElement = $domDocument->createElement('file', $this->file);
|
$fileElement = $domDocument->createElement('file', $this->file);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class JoinServer implements Element {
|
class JoinServer extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class JoinServer implements Element {
|
|||||||
* Create a new JoinServer object
|
* Create a new JoinServer object
|
||||||
*
|
*
|
||||||
* @param string $login (optional) Server login
|
* @param string $login (optional) Server login
|
||||||
* @return \FML\ManiaCode\JoinServer|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($login = null) {
|
public static function create($login = null) {
|
||||||
return new static($login);
|
return new static($login);
|
||||||
@ -43,7 +43,7 @@ class JoinServer implements Element {
|
|||||||
* Set the server login
|
* Set the server login
|
||||||
*
|
*
|
||||||
* @param string $login Server login
|
* @param string $login Server login
|
||||||
* @return \FML\ManiaCode\JoinServer|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLogin($login) {
|
public function setLogin($login) {
|
||||||
$this->login = (string)$login;
|
$this->login = (string)$login;
|
||||||
@ -57,7 +57,7 @@ class JoinServer implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $serverIp Server ip
|
* @param string $serverIp Server ip
|
||||||
* @param int $serverPort Server port
|
* @param int $serverPort Server port
|
||||||
* @return \FML\ManiaCode\JoinServer|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setIp($serverIp, $serverPort) {
|
public function setIp($serverIp, $serverPort) {
|
||||||
$this->serverIp = (string)$serverIp;
|
$this->serverIp = (string)$serverIp;
|
||||||
@ -70,7 +70,7 @@ class JoinServer implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
if (is_null($this->serverIp)) {
|
if (is_null($this->serverIp)) {
|
||||||
$loginElement = $domDocument->createElement('login', $this->login);
|
$loginElement = $domDocument->createElement('login', $this->login);
|
||||||
$xmlElement->appendChild($loginElement);
|
$xmlElement->appendChild($loginElement);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class PlayMap implements Element {
|
class PlayMap extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class PlayMap implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Map name
|
* @param string $name (optional) Map name
|
||||||
* @param string $url (optional) Map url
|
* @param string $url (optional) Map url
|
||||||
* @return \FML\ManiaCode\PlayMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -47,7 +47,7 @@ class PlayMap implements Element {
|
|||||||
* Set the name of the map
|
* Set the name of the map
|
||||||
*
|
*
|
||||||
* @param string $name Map name
|
* @param string $name Map name
|
||||||
* @return \FML\ManiaCode\PlayMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -58,7 +58,7 @@ class PlayMap implements Element {
|
|||||||
* Set the url of the map
|
* Set the url of the map
|
||||||
*
|
*
|
||||||
* @param string $url Map url
|
* @param string $url Map url
|
||||||
* @return \FML\ManiaCode\PlayMap|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -69,7 +69,7 @@ class PlayMap implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$urlElement = $domDocument->createElement('url', $this->url);
|
$urlElement = $domDocument->createElement('url', $this->url);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class PlayReplay implements Element {
|
class PlayReplay extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class PlayReplay implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Replay name
|
* @param string $name (optional) Replay name
|
||||||
* @param string $url (optional) Replay url
|
* @param string $url (optional) Replay url
|
||||||
* @return \FML\ManiaCode\PlayReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -47,7 +47,7 @@ class PlayReplay implements Element {
|
|||||||
* Set the name of the replay
|
* Set the name of the replay
|
||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @return \FML\ManiaCode\PlayReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -58,7 +58,7 @@ class PlayReplay implements Element {
|
|||||||
* Set the url of the replay
|
* Set the url of the replay
|
||||||
*
|
*
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode\PlayReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -69,7 +69,7 @@ class PlayReplay implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$urlElement = $domDocument->createElement('url', $this->url);
|
$urlElement = $domDocument->createElement('url', $this->url);
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class ShowMessage implements Element {
|
class ShowMessage extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -20,7 +20,7 @@ class ShowMessage implements Element {
|
|||||||
* Create a new ShowMessage object
|
* Create a new ShowMessage object
|
||||||
*
|
*
|
||||||
* @param string $message (optional) Message text
|
* @param string $message (optional) Message text
|
||||||
* @return \FML\ManiaCode\ShowMessage|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($message = null) {
|
public static function create($message = null) {
|
||||||
return new static($message);
|
return new static($message);
|
||||||
@ -41,7 +41,7 @@ class ShowMessage implements Element {
|
|||||||
* Set the message text
|
* Set the message text
|
||||||
*
|
*
|
||||||
* @param string $message Message text
|
* @param string $message Message text
|
||||||
* @return \FML\ManiaCode\ShowMessage|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setMessage($message) {
|
public function setMessage($message) {
|
||||||
$this->message = (string)$message;
|
$this->message = (string)$message;
|
||||||
@ -52,7 +52,7 @@ class ShowMessage implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$messageElement = $domDocument->createElement('message', $this->message);
|
$messageElement = $domDocument->createElement('message', $this->message);
|
||||||
$xmlElement->appendChild($messageElement);
|
$xmlElement->appendChild($messageElement);
|
||||||
return $xmlElement;
|
return $xmlElement;
|
||||||
|
@ -9,7 +9,7 @@ namespace FML\ManiaCode;
|
|||||||
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
* @copyright FancyManiaLinks Copyright © 2014 Steffen Schröder
|
||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
class ViewReplay implements Element {
|
class ViewReplay extends Element {
|
||||||
/*
|
/*
|
||||||
* Protected properties
|
* Protected properties
|
||||||
*/
|
*/
|
||||||
@ -22,7 +22,7 @@ class ViewReplay implements Element {
|
|||||||
*
|
*
|
||||||
* @param string $name (optional) Replay name
|
* @param string $name (optional) Replay name
|
||||||
* @param string $url (optional) Replay url
|
* @param string $url (optional) Replay url
|
||||||
* @return \FML\ManiaCode\ViewReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($name = null, $url = null) {
|
public static function create($name = null, $url = null) {
|
||||||
return new static($name, $url);
|
return new static($name, $url);
|
||||||
@ -47,7 +47,7 @@ class ViewReplay implements Element {
|
|||||||
* Set the name of the replay
|
* Set the name of the replay
|
||||||
*
|
*
|
||||||
* @param string $name Replay name
|
* @param string $name Replay name
|
||||||
* @return \FML\ManiaCode\ViewReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -58,7 +58,7 @@ class ViewReplay implements Element {
|
|||||||
* Set the url of the replay
|
* Set the url of the replay
|
||||||
*
|
*
|
||||||
* @param string $url Replay url
|
* @param string $url Replay url
|
||||||
* @return \FML\ManiaCode\ViewReplay|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -69,7 +69,7 @@ class ViewReplay implements Element {
|
|||||||
* @see \FML\ManiaCode\Element::render()
|
* @see \FML\ManiaCode\Element::render()
|
||||||
*/
|
*/
|
||||||
public function render(\DOMDocument $domDocument) {
|
public function render(\DOMDocument $domDocument) {
|
||||||
$xmlElement = $domDocument->createElement($this->tagName);
|
$xmlElement = parent::render($domDocument);
|
||||||
$nameElement = $domDocument->createElement('name', $this->name);
|
$nameElement = $domDocument->createElement('name', $this->name);
|
||||||
$xmlElement->appendChild($nameElement);
|
$xmlElement->appendChild($nameElement);
|
||||||
$urlElement = $domDocument->createElement('url', $this->url);
|
$urlElement = $domDocument->createElement('url', $this->url);
|
||||||
|
@ -34,6 +34,7 @@ class ManiaLink {
|
|||||||
protected $version = 1;
|
protected $version = 1;
|
||||||
protected $background = null;
|
protected $background = null;
|
||||||
protected $navigable3d = 1;
|
protected $navigable3d = 1;
|
||||||
|
protected $name = null;
|
||||||
protected $timeout = 0;
|
protected $timeout = 0;
|
||||||
/** @var Renderable[] $children */
|
/** @var Renderable[] $children */
|
||||||
protected $children = array();
|
protected $children = array();
|
||||||
@ -48,7 +49,7 @@ class ManiaLink {
|
|||||||
* Create a new ManiaLink object
|
* Create a new ManiaLink object
|
||||||
*
|
*
|
||||||
* @param string $maniaLinkId (optional) ManiaLink id
|
* @param string $maniaLinkId (optional) ManiaLink id
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($maniaLinkId = null) {
|
public static function create($maniaLinkId = null) {
|
||||||
return new static($maniaLinkId);
|
return new static($maniaLinkId);
|
||||||
@ -69,7 +70,7 @@ class ManiaLink {
|
|||||||
* Set XML encoding
|
* Set XML encoding
|
||||||
*
|
*
|
||||||
* @param string $encoding XML encoding
|
* @param string $encoding XML encoding
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setXmlEncoding($encoding) {
|
public function setXmlEncoding($encoding) {
|
||||||
$this->encoding = (string)$encoding;
|
$this->encoding = (string)$encoding;
|
||||||
@ -80,7 +81,7 @@ class ManiaLink {
|
|||||||
* Set ManiaLink id
|
* Set ManiaLink id
|
||||||
*
|
*
|
||||||
* @param string $maniaLinkId ManiaLink id
|
* @param string $maniaLinkId ManiaLink id
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setId($maniaLinkId) {
|
public function setId($maniaLinkId) {
|
||||||
$this->maniaLinkId = (string)$maniaLinkId;
|
$this->maniaLinkId = (string)$maniaLinkId;
|
||||||
@ -100,7 +101,7 @@ class ManiaLink {
|
|||||||
* Set background
|
* Set background
|
||||||
*
|
*
|
||||||
* @param string $background Background value
|
* @param string $background Background value
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setBackground($background) {
|
public function setBackground($background) {
|
||||||
$this->background = (string)$background;
|
$this->background = (string)$background;
|
||||||
@ -111,18 +112,29 @@ class ManiaLink {
|
|||||||
* Set navigable3d
|
* Set navigable3d
|
||||||
*
|
*
|
||||||
* @param bool $navigable3d Whether the manialink should be 3d navigable
|
* @param bool $navigable3d Whether the manialink should be 3d navigable
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setNavigable3d($navigable3d) {
|
public function setNavigable3d($navigable3d) {
|
||||||
$this->navigable3d = ($navigable3d ? 1 : 0);
|
$this->navigable3d = ($navigable3d ? 1 : 0);
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the ManiaLink Name
|
||||||
|
*
|
||||||
|
* @param string $name
|
||||||
|
* @return static
|
||||||
|
*/
|
||||||
|
public function setName($name) {
|
||||||
|
$this->name = (string)$name;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set timeout
|
* Set timeout
|
||||||
*
|
*
|
||||||
* @param int $timeout Timeout duration
|
* @param int $timeout Timeout duration
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTimeout($timeout) {
|
public function setTimeout($timeout) {
|
||||||
$this->timeout = (int)$timeout;
|
$this->timeout = (int)$timeout;
|
||||||
@ -133,7 +145,7 @@ class ManiaLink {
|
|||||||
* Add an element to the ManiaLink
|
* Add an element to the ManiaLink
|
||||||
*
|
*
|
||||||
* @param Renderable $child Child element to add
|
* @param Renderable $child Child element to add
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function add(Renderable $child) {
|
public function add(Renderable $child) {
|
||||||
if (!in_array($child, $this->children, true)) {
|
if (!in_array($child, $this->children, true)) {
|
||||||
@ -145,7 +157,7 @@ class ManiaLink {
|
|||||||
/**
|
/**
|
||||||
* Remove all elements from the ManiaLink
|
* Remove all elements from the ManiaLink
|
||||||
*
|
*
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeChildren() {
|
public function removeChildren() {
|
||||||
$this->children = array();
|
$this->children = array();
|
||||||
@ -156,7 +168,7 @@ class ManiaLink {
|
|||||||
* Set the Dictionary of the ManiaLink
|
* Set the Dictionary of the ManiaLink
|
||||||
*
|
*
|
||||||
* @param Dico $dico Dictionary for the ManiaLink
|
* @param Dico $dico Dictionary for the ManiaLink
|
||||||
* @return \FML\ManiaLink
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDico(Dico $dico) {
|
public function setDico(Dico $dico) {
|
||||||
$this->dico = $dico;
|
$this->dico = $dico;
|
||||||
@ -180,7 +192,7 @@ class ManiaLink {
|
|||||||
* Set the Stylesheet of the ManiaLink
|
* Set the Stylesheet of the ManiaLink
|
||||||
*
|
*
|
||||||
* @param Stylesheet $stylesheet Stylesheet for the ManiaLink
|
* @param Stylesheet $stylesheet Stylesheet for the ManiaLink
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStylesheet(Stylesheet $stylesheet) {
|
public function setStylesheet(Stylesheet $stylesheet) {
|
||||||
$this->stylesheet = $stylesheet;
|
$this->stylesheet = $stylesheet;
|
||||||
@ -204,7 +216,7 @@ class ManiaLink {
|
|||||||
* Set the Script of the ManiaLink
|
* Set the Script of the ManiaLink
|
||||||
*
|
*
|
||||||
* @param Script $script Script for the ManiaLink
|
* @param Script $script Script for the ManiaLink
|
||||||
* @return \FML\ManiaLink|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setScript(Script $script) {
|
public function setScript(Script $script) {
|
||||||
$this->script = $script;
|
$this->script = $script;
|
||||||
@ -253,6 +265,9 @@ class ManiaLink {
|
|||||||
if (!$this->navigable3d) {
|
if (!$this->navigable3d) {
|
||||||
$maniaLink->setAttribute('navigable3d', $this->navigable3d);
|
$maniaLink->setAttribute('navigable3d', $this->navigable3d);
|
||||||
}
|
}
|
||||||
|
if ($this->name) {
|
||||||
|
$maniaLink->setAttribute('name', $this->name);
|
||||||
|
}
|
||||||
if ($this->timeout) {
|
if ($this->timeout) {
|
||||||
$timeoutXml = $domDocument->createElement('timeout', $this->timeout);
|
$timeoutXml = $domDocument->createElement('timeout', $this->timeout);
|
||||||
$maniaLink->appendChild($timeoutXml);
|
$maniaLink->appendChild($timeoutXml);
|
||||||
|
@ -23,7 +23,7 @@ class ManiaLinks {
|
|||||||
/**
|
/**
|
||||||
* Create a new ManiaLinks object
|
* Create a new ManiaLinks object
|
||||||
*
|
*
|
||||||
* @return \FML\ManiaLinks|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -33,7 +33,7 @@ class ManiaLinks {
|
|||||||
* Set XML encoding
|
* Set XML encoding
|
||||||
*
|
*
|
||||||
* @param string $encoding XML encoding
|
* @param string $encoding XML encoding
|
||||||
* @return \FML\ManiaLinks|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setXmlEncoding($encoding) {
|
public function setXmlEncoding($encoding) {
|
||||||
$this->encoding = (string)$encoding;
|
$this->encoding = (string)$encoding;
|
||||||
@ -44,7 +44,7 @@ class ManiaLinks {
|
|||||||
* Add a child ManiaLink
|
* Add a child ManiaLink
|
||||||
*
|
*
|
||||||
* @param ManiaLink $child Child ManiaLink
|
* @param ManiaLink $child Child ManiaLink
|
||||||
* @return \FML\ManiaLinks
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function add(ManiaLink $child) {
|
public function add(ManiaLink $child) {
|
||||||
if (!in_array($child, $this->children, true)) {
|
if (!in_array($child, $this->children, true)) {
|
||||||
@ -56,7 +56,7 @@ class ManiaLinks {
|
|||||||
/**
|
/**
|
||||||
* Remove all child ManiaLinks
|
* Remove all child ManiaLinks
|
||||||
*
|
*
|
||||||
* @return \FML\ManiaLinks|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeChildren() {
|
public function removeChildren() {
|
||||||
$this->children = array();
|
$this->children = array();
|
||||||
@ -67,7 +67,7 @@ class ManiaLinks {
|
|||||||
* Set the CustomUI
|
* Set the CustomUI
|
||||||
*
|
*
|
||||||
* @param CustomUI $customUI CustomUI object
|
* @param CustomUI $customUI CustomUI object
|
||||||
* @return \FML\ManiaLinks|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCustomUI(CustomUI $customUI) {
|
public function setCustomUI(CustomUI $customUI) {
|
||||||
$this->customUI = $customUI;
|
$this->customUI = $customUI;
|
||||||
|
@ -26,7 +26,7 @@ class CheckBoxDesign implements Styleable, SubStyleable {
|
|||||||
/**
|
/**
|
||||||
* Create the default enabled Design
|
* Create the default enabled Design
|
||||||
*
|
*
|
||||||
* @return \FML\Models\CheckBoxDesign|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function defaultEnabledDesign() {
|
public static function defaultEnabledDesign() {
|
||||||
return new static(Quad_Icons64x64_1::STYLE, Quad_Icons64x64_1::SUBSTYLE_Check);
|
return new static(Quad_Icons64x64_1::STYLE, Quad_Icons64x64_1::SUBSTYLE_Check);
|
||||||
@ -35,7 +35,7 @@ class CheckBoxDesign implements Styleable, SubStyleable {
|
|||||||
/**
|
/**
|
||||||
* Create the default disabled Design
|
* Create the default disabled Design
|
||||||
*
|
*
|
||||||
* @return \FML\Models\CheckBoxDesign|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function defaultDisabledDesign() {
|
public static function defaultDisabledDesign() {
|
||||||
return new static(Quad_Icons64x64_1::STYLE, Quad_Icons64x64_1::SUBSTYLE_Check);
|
return new static(Quad_Icons64x64_1::STYLE, Quad_Icons64x64_1::SUBSTYLE_Check);
|
||||||
@ -60,7 +60,7 @@ class CheckBoxDesign implements Styleable, SubStyleable {
|
|||||||
* Set the image url
|
* Set the image url
|
||||||
*
|
*
|
||||||
* @param string $url Image url
|
* @param string $url Image url
|
||||||
* @return \FML\Models\CheckBoxDesign|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setImageUrl($url) {
|
public function setImageUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
@ -100,7 +100,7 @@ class CheckBoxDesign implements Styleable, SubStyleable {
|
|||||||
* Apply the Design to the given Quad
|
* Apply the Design to the given Quad
|
||||||
*
|
*
|
||||||
* @param Quad $quad CheckBox Quad
|
* @param Quad $quad CheckBox Quad
|
||||||
* @return \FML\Models\CheckBoxDesign|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function applyToQuad(Quad $quad) {
|
public function applyToQuad(Quad $quad) {
|
||||||
$quad->setImage($this->url);
|
$quad->setImage($this->url);
|
||||||
|
@ -47,7 +47,7 @@ class ActionTrigger extends ScriptFeature {
|
|||||||
* Set the action to trigger
|
* Set the action to trigger
|
||||||
*
|
*
|
||||||
* @param string $actionName
|
* @param string $actionName
|
||||||
* @return \FML\Script\Features\ActionTrigger|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setActionName($actionName) {
|
public function setActionName($actionName) {
|
||||||
$this->actionName = (string)$actionName;
|
$this->actionName = (string)$actionName;
|
||||||
@ -58,7 +58,7 @@ class ActionTrigger extends ScriptFeature {
|
|||||||
* Set the Control
|
* Set the Control
|
||||||
*
|
*
|
||||||
* @param Control $control Action Control
|
* @param Control $control Action Control
|
||||||
* @return \FML\Script\Features\ActionTrigger|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -73,7 +73,7 @@ class ActionTrigger extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label name
|
* @param string $labelName Script Label name
|
||||||
* @return \FML\Script\Features\ActionTrigger|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
|
@ -64,7 +64,7 @@ class CheckBoxFeature extends ScriptFeature {
|
|||||||
* Set the CheckBox Quad
|
* Set the CheckBox Quad
|
||||||
*
|
*
|
||||||
* @param Quad $quad CheckBox Quad
|
* @param Quad $quad CheckBox Quad
|
||||||
* @return \FML\Script\Features\CheckBoxFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setQuad(Quad $quad) {
|
public function setQuad(Quad $quad) {
|
||||||
$this->quad = $quad->checkId()->setScriptEvents(true);
|
$this->quad = $quad->checkId()->setScriptEvents(true);
|
||||||
@ -84,7 +84,7 @@ class CheckBoxFeature extends ScriptFeature {
|
|||||||
* Set the CheckBox Entry
|
* Set the CheckBox Entry
|
||||||
*
|
*
|
||||||
* @param Entry $entry CheckBox Entry
|
* @param Entry $entry CheckBox Entry
|
||||||
* @return \FML\Script\Features\CheckBoxFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEntry(Entry $entry) {
|
public function setEntry(Entry $entry) {
|
||||||
$this->entry = $entry->checkId();
|
$this->entry = $entry->checkId();
|
||||||
@ -104,7 +104,7 @@ class CheckBoxFeature extends ScriptFeature {
|
|||||||
* Set the default value
|
* Set the default value
|
||||||
*
|
*
|
||||||
* @param bool $default Default value
|
* @param bool $default Default value
|
||||||
* @return \FML\Script\Features\CheckBoxFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDefault($default) {
|
public function setDefault($default) {
|
||||||
$this->default = (bool)$default;
|
$this->default = (bool)$default;
|
||||||
@ -115,7 +115,7 @@ class CheckBoxFeature extends ScriptFeature {
|
|||||||
* Set the enabled Design
|
* Set the enabled Design
|
||||||
*
|
*
|
||||||
* @param CheckBoxDesign $checkBoxDesign Enabled CheckBox Design
|
* @param CheckBoxDesign $checkBoxDesign Enabled CheckBox Design
|
||||||
* @return \FML\Script\Features\CheckBoxFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEnabledDesign(CheckBoxDesign $checkBoxDesign) {
|
public function setEnabledDesign(CheckBoxDesign $checkBoxDesign) {
|
||||||
$this->enabledDesign = $checkBoxDesign;
|
$this->enabledDesign = $checkBoxDesign;
|
||||||
@ -126,7 +126,7 @@ class CheckBoxFeature extends ScriptFeature {
|
|||||||
* Set the disabled Design
|
* Set the disabled Design
|
||||||
*
|
*
|
||||||
* @param CheckBoxDesign $checkBoxDesign Disabled CheckBox Design
|
* @param CheckBoxDesign $checkBoxDesign Disabled CheckBox Design
|
||||||
* @return \FML\Script\Features\CheckBoxFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDisabledDesign(CheckBoxDesign $checkBoxDesign) {
|
public function setDisabledDesign(CheckBoxDesign $checkBoxDesign) {
|
||||||
$this->disabledDesign = $checkBoxDesign;
|
$this->disabledDesign = $checkBoxDesign;
|
||||||
|
@ -42,7 +42,7 @@ class Clock extends ScriptFeature {
|
|||||||
* Set the Label
|
* Set the Label
|
||||||
*
|
*
|
||||||
* @param Label $label Clock Label
|
* @param Label $label Clock Label
|
||||||
* @return \FML\Script\Features\Clock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabel(Label $label) {
|
public function setLabel(Label $label) {
|
||||||
$this->label = $label->checkId();
|
$this->label = $label->checkId();
|
||||||
@ -53,7 +53,7 @@ class Clock extends ScriptFeature {
|
|||||||
* Set whether seconds should be shown
|
* Set whether seconds should be shown
|
||||||
*
|
*
|
||||||
* @param bool $showSeconds Whether seconds should be shown
|
* @param bool $showSeconds Whether seconds should be shown
|
||||||
* @return \FML\Script\Features\Clock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setShowSeconds($showSeconds) {
|
public function setShowSeconds($showSeconds) {
|
||||||
$this->showSeconds = (bool)$showSeconds;
|
$this->showSeconds = (bool)$showSeconds;
|
||||||
@ -64,7 +64,7 @@ class Clock extends ScriptFeature {
|
|||||||
* Set whether the full date should be shown
|
* Set whether the full date should be shown
|
||||||
*
|
*
|
||||||
* @param bool $showFullDate Whether the full date should be shown
|
* @param bool $showFullDate Whether the full date should be shown
|
||||||
* @return \FML\Script\Features\Clock|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setShowFullDate($showFullDate) {
|
public function setShowFullDate($showFullDate) {
|
||||||
$this->showFullDate = (bool)$showFullDate;
|
$this->showFullDate = (bool)$showFullDate;
|
||||||
|
@ -40,7 +40,7 @@ class ControlScript extends ScriptFeature {
|
|||||||
* Set the Control
|
* Set the Control
|
||||||
*
|
*
|
||||||
* @param Control $control Event Control
|
* @param Control $control Event Control
|
||||||
* @return \FML\Script\Features\ControlScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$this->control = $control->checkId();
|
$this->control = $control->checkId();
|
||||||
@ -52,7 +52,7 @@ class ControlScript extends ScriptFeature {
|
|||||||
* Set the script text
|
* Set the script text
|
||||||
*
|
*
|
||||||
* @param string $text Script text
|
* @param string $text Script text
|
||||||
* @return \FML\Script\Features\ControlScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
@ -63,7 +63,7 @@ class ControlScript extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label name
|
* @param string $labelName Script Label name
|
||||||
* @return \FML\Script\Features\ControlScript|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
|
@ -40,7 +40,7 @@ class EntrySubmit extends ScriptFeature {
|
|||||||
* Set the Entry
|
* Set the Entry
|
||||||
*
|
*
|
||||||
* @param Entry $entry Entry Control
|
* @param Entry $entry Entry Control
|
||||||
* @return \FML\Script\Features\EntrySubmit|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEntry(Entry $entry) {
|
public function setEntry(Entry $entry) {
|
||||||
$this->entry = $entry->checkId()->setScriptEvents(true);
|
$this->entry = $entry->checkId()->setScriptEvents(true);
|
||||||
@ -51,7 +51,7 @@ class EntrySubmit extends ScriptFeature {
|
|||||||
* Set the submit url
|
* Set the submit url
|
||||||
*
|
*
|
||||||
* @param string $url Submit url
|
* @param string $url Submit url
|
||||||
* @return \FML\Script\Features\EntrySubmit|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url) {
|
public function setUrl($url) {
|
||||||
$this->url = (string)$url;
|
$this->url = (string)$url;
|
||||||
|
@ -42,7 +42,7 @@ class KeyAction extends ScriptFeature {
|
|||||||
* Set the action to trigger
|
* Set the action to trigger
|
||||||
*
|
*
|
||||||
* @param string $actionName Triggered action
|
* @param string $actionName Triggered action
|
||||||
* @return \FML\Script\Features\KeyAction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setActionName($actionName) {
|
public function setActionName($actionName) {
|
||||||
$this->actionName = (string)$actionName;
|
$this->actionName = (string)$actionName;
|
||||||
@ -53,7 +53,7 @@ class KeyAction extends ScriptFeature {
|
|||||||
* Set the key name for triggering the action
|
* Set the key name for triggering the action
|
||||||
*
|
*
|
||||||
* @param string $keyName Key Name
|
* @param string $keyName Key Name
|
||||||
* @return \FML\Script\Features\KeyAction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setKeyName($keyName) {
|
public function setKeyName($keyName) {
|
||||||
$this->keyName = (string)$keyName;
|
$this->keyName = (string)$keyName;
|
||||||
@ -66,7 +66,7 @@ class KeyAction extends ScriptFeature {
|
|||||||
* Set the key code for triggering the action
|
* Set the key code for triggering the action
|
||||||
*
|
*
|
||||||
* @param int $keyCode Key Code
|
* @param int $keyCode Key Code
|
||||||
* @return \FML\Script\Features\KeyAction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setKeyCode($keyCode) {
|
public function setKeyCode($keyCode) {
|
||||||
$this->keyCode = (int)$keyCode;
|
$this->keyCode = (int)$keyCode;
|
||||||
@ -79,7 +79,7 @@ class KeyAction extends ScriptFeature {
|
|||||||
* Set the char to press for triggering the action
|
* Set the char to press for triggering the action
|
||||||
*
|
*
|
||||||
* @param string $charPressed Pressed char
|
* @param string $charPressed Pressed char
|
||||||
* @return \FML\Script\Features\KeyAction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCharPressed($charPressed) {
|
public function setCharPressed($charPressed) {
|
||||||
$this->charPressed = (string)$charPressed;
|
$this->charPressed = (string)$charPressed;
|
||||||
|
@ -38,7 +38,7 @@ class MapInfo extends ScriptFeature {
|
|||||||
* Set the Control
|
* Set the Control
|
||||||
*
|
*
|
||||||
* @param Control $control Map Info Control
|
* @param Control $control Map Info Control
|
||||||
* @return \FML\Script\Features\MapInfo|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -53,7 +53,7 @@ class MapInfo extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label name
|
* @param string $labelName Script Label name
|
||||||
* @return \FML\Script\Features\MapInfo|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
|
@ -46,7 +46,7 @@ class Menu extends ScriptFeature {
|
|||||||
* @param Control $item Item Control in the Menu bar
|
* @param Control $item Item Control in the Menu bar
|
||||||
* @param Control $control Toggled Menu Control
|
* @param Control $control Toggled Menu Control
|
||||||
* @param bool $isStartElement (optional) Whether the Menu should start with this Element
|
* @param bool $isStartElement (optional) Whether the Menu should start with this Element
|
||||||
* @return \FML\Script\Features\Menu|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addElement(Control $item, Control $control, $isStartElement = false) {
|
public function addElement(Control $item, Control $control, $isStartElement = false) {
|
||||||
$menuElement = new MenuElement($item, $control);
|
$menuElement = new MenuElement($item, $control);
|
||||||
@ -59,7 +59,7 @@ class Menu extends ScriptFeature {
|
|||||||
*
|
*
|
||||||
* @param MenuElement $menuElement Menu Element
|
* @param MenuElement $menuElement Menu Element
|
||||||
* @param bool $isStartElement (optional) Whether the Menu should start with this Element
|
* @param bool $isStartElement (optional) Whether the Menu should start with this Element
|
||||||
* @return \FML\Script\Features\Menu|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function appendElement(MenuElement $menuElement, $isStartElement = false) {
|
public function appendElement(MenuElement $menuElement, $isStartElement = false) {
|
||||||
if (!in_array($menuElement, $this->elements, true)) {
|
if (!in_array($menuElement, $this->elements, true)) {
|
||||||
@ -77,7 +77,7 @@ class Menu extends ScriptFeature {
|
|||||||
* Set the Element to start with
|
* Set the Element to start with
|
||||||
*
|
*
|
||||||
* @param MenuElement $startElement Starting Element
|
* @param MenuElement $startElement Starting Element
|
||||||
* @return \FML\Script\Features\Menu|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStartElement(MenuElement $startElement) {
|
public function setStartElement(MenuElement $startElement) {
|
||||||
$this->startElement = $startElement;
|
$this->startElement = $startElement;
|
||||||
|
@ -38,7 +38,7 @@ class MenuElement {
|
|||||||
* Set the Item Control
|
* Set the Item Control
|
||||||
*
|
*
|
||||||
* @param Control $item Item Control in the Menu bar
|
* @param Control $item Item Control in the Menu bar
|
||||||
* @return \FML\Script\Features\MenuElement|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setItem(Control $item) {
|
public function setItem(Control $item) {
|
||||||
$item->checkId();
|
$item->checkId();
|
||||||
@ -62,7 +62,7 @@ class MenuElement {
|
|||||||
* Set the Menu Control
|
* Set the Menu Control
|
||||||
*
|
*
|
||||||
* @param Control $control Toggled Menu Control
|
* @param Control $control Toggled Menu Control
|
||||||
* @return \FML\Script\Features\MenuElement|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$this->control = $control->checkId();
|
$this->control = $control->checkId();
|
||||||
|
@ -54,7 +54,7 @@ class Paging extends ScriptFeature {
|
|||||||
*
|
*
|
||||||
* @param Control $pageControl Page Control
|
* @param Control $pageControl Page Control
|
||||||
* @param string $pageNumber (optional) Page number
|
* @param string $pageNumber (optional) Page number
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addPage(Control $pageControl, $pageNumber = null) {
|
public function addPage(Control $pageControl, $pageNumber = null) {
|
||||||
if (is_null($pageNumber)) {
|
if (is_null($pageNumber)) {
|
||||||
@ -69,7 +69,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Append a Page
|
* Append a Page
|
||||||
*
|
*
|
||||||
* @param PagingPage $page Paging Page
|
* @param PagingPage $page Paging Page
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function appendPage(PagingPage $page) {
|
public function appendPage(PagingPage $page) {
|
||||||
if (!in_array($page, $this->pages, true)) {
|
if (!in_array($page, $this->pages, true)) {
|
||||||
@ -83,7 +83,7 @@ class Paging extends ScriptFeature {
|
|||||||
*
|
*
|
||||||
* @param Control $buttonControl Button used for browsing
|
* @param Control $buttonControl Button used for browsing
|
||||||
* @param int $browseAction (optional) Number of browsed Pages per click
|
* @param int $browseAction (optional) Number of browsed Pages per click
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addButton(Control $buttonControl, $browseAction = null) {
|
public function addButton(Control $buttonControl, $browseAction = null) {
|
||||||
if (is_null($browseAction)) {
|
if (is_null($browseAction)) {
|
||||||
@ -103,7 +103,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Append a Button to browse through Pages
|
* Append a Button to browse through Pages
|
||||||
*
|
*
|
||||||
* @param PagingButton $button Paging Button
|
* @param PagingButton $button Paging Button
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function appendButton(PagingButton $button) {
|
public function appendButton(PagingButton $button) {
|
||||||
if (!in_array($button, $this->buttons, true)) {
|
if (!in_array($button, $this->buttons, true)) {
|
||||||
@ -116,7 +116,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set the Label showing the Page number
|
* Set the Label showing the Page number
|
||||||
*
|
*
|
||||||
* @param Label $label Page number Label
|
* @param Label $label Page number Label
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabel(Label $label) {
|
public function setLabel(Label $label) {
|
||||||
$this->label = $label->checkId();
|
$this->label = $label->checkId();
|
||||||
@ -127,7 +127,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set the Start Page number
|
* Set the Start Page number
|
||||||
*
|
*
|
||||||
* @param int $startPageNumber Page number to start with
|
* @param int $startPageNumber Page number to start with
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStartPageNumber($startPageNumber) {
|
public function setStartPageNumber($startPageNumber) {
|
||||||
$this->startPageNumber = (int)$startPageNumber;
|
$this->startPageNumber = (int)$startPageNumber;
|
||||||
@ -137,7 +137,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set a custom maximum Page number for using chunks
|
* Set a custom maximum Page number for using chunks
|
||||||
*
|
*
|
||||||
* @param int $maxPageNumber Custom maximum Page number
|
* @param int $maxPageNumber Custom maximum Page number
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCustomMaxPageNumber($maxPageNumber) {
|
public function setCustomMaxPageNumber($maxPageNumber) {
|
||||||
$this->customMaxPageNumber = (int)$maxPageNumber;
|
$this->customMaxPageNumber = (int)$maxPageNumber;
|
||||||
@ -148,7 +148,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set the action triggered when the previous chunk is needed
|
* Set the action triggered when the previous chunk is needed
|
||||||
*
|
*
|
||||||
* @param string $previousChunkAction Triggered action
|
* @param string $previousChunkAction Triggered action
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setPreviousChunkAction($previousChunkAction) {
|
public function setPreviousChunkAction($previousChunkAction) {
|
||||||
$this->previousChunkAction = (string)$previousChunkAction;
|
$this->previousChunkAction = (string)$previousChunkAction;
|
||||||
@ -159,7 +159,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set the action triggered when the next chunk is needed
|
* Set the action triggered when the next chunk is needed
|
||||||
*
|
*
|
||||||
* @param string $nextChunkAction Triggered action
|
* @param string $nextChunkAction Triggered action
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setNextChunkAction($nextChunkAction) {
|
public function setNextChunkAction($nextChunkAction) {
|
||||||
$this->nextChunkAction = (string)$nextChunkAction;
|
$this->nextChunkAction = (string)$nextChunkAction;
|
||||||
@ -170,7 +170,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set the actions triggered when another chunk is needed
|
* Set the actions triggered when another chunk is needed
|
||||||
*
|
*
|
||||||
* @param string $chunkAction Triggered action
|
* @param string $chunkAction Triggered action
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setChunkActions($chunkAction) {
|
public function setChunkActions($chunkAction) {
|
||||||
$this->setNextChunkAction($chunkAction);
|
$this->setNextChunkAction($chunkAction);
|
||||||
@ -182,7 +182,7 @@ class Paging extends ScriptFeature {
|
|||||||
* Set if the chunk action should get the needed Page number appended
|
* Set if the chunk action should get the needed Page number appended
|
||||||
*
|
*
|
||||||
* @param bool $appendPageNumber Whether to append the needed Page number
|
* @param bool $appendPageNumber Whether to append the needed Page number
|
||||||
* @return \FML\Script\Features\Paging|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setChunkActionAppendsPageNumber($appendPageNumber) {
|
public function setChunkActionAppendsPageNumber($appendPageNumber) {
|
||||||
$this->chunkActionAppendsPageNumber = (bool)$appendPageNumber;
|
$this->chunkActionAppendsPageNumber = (bool)$appendPageNumber;
|
||||||
|
@ -39,7 +39,7 @@ class PagingButton {
|
|||||||
* Set the Button Control
|
* Set the Button Control
|
||||||
*
|
*
|
||||||
* @param Control $control Browse Control
|
* @param Control $control Browse Control
|
||||||
* @return \FML\Script\Features\PagingButton|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -63,7 +63,7 @@ class PagingButton {
|
|||||||
* Set the browse action
|
* Set the browse action
|
||||||
*
|
*
|
||||||
* @param int $browseAction Number of browsed Pages per click
|
* @param int $browseAction Number of browsed Pages per click
|
||||||
* @return \FML\Script\Features\PagingButton|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setBrowseAction($browseAction) {
|
public function setBrowseAction($browseAction) {
|
||||||
$this->browseAction = (int)$browseAction;
|
$this->browseAction = (int)$browseAction;
|
||||||
|
@ -36,7 +36,7 @@ class PagingPage {
|
|||||||
* Set the Page Control
|
* Set the Page Control
|
||||||
*
|
*
|
||||||
* @param Control $control Page Control
|
* @param Control $control Page Control
|
||||||
* @return \FML\Script\Features\PagingPage|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$this->control = $control->checkId();
|
$this->control = $control->checkId();
|
||||||
@ -56,7 +56,7 @@ class PagingPage {
|
|||||||
* Set the Page number
|
* Set the Page number
|
||||||
*
|
*
|
||||||
* @param int $pageNumber Number of the Page
|
* @param int $pageNumber Number of the Page
|
||||||
* @return \FML\Script\Features\PagingPage|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setPageNumber($pageNumber) {
|
public function setPageNumber($pageNumber) {
|
||||||
$this->number = (int)$pageNumber;
|
$this->number = (int)$pageNumber;
|
||||||
|
@ -43,7 +43,7 @@ class PlayerProfile extends ScriptFeature {
|
|||||||
* Set the login of the opened player
|
* Set the login of the opened player
|
||||||
*
|
*
|
||||||
* @param string $login Player login
|
* @param string $login Player login
|
||||||
* @return \FML\Script\Features\PlayerProfile|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLogin($login) {
|
public function setLogin($login) {
|
||||||
$this->login = $login;
|
$this->login = $login;
|
||||||
@ -54,7 +54,7 @@ class PlayerProfile extends ScriptFeature {
|
|||||||
* Set the Control
|
* Set the Control
|
||||||
*
|
*
|
||||||
* @param Control $control Profile Control
|
* @param Control $control Profile Control
|
||||||
* @return \FML\Script\Features\PlayerProfile|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -69,7 +69,7 @@ class PlayerProfile extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label name
|
* @param string $labelName Script Label name
|
||||||
* @return \FML\Script\Features\PlayerProfile|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
|
@ -13,10 +13,10 @@ use FML\Types\ScriptFeatureable;
|
|||||||
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
|
||||||
*/
|
*/
|
||||||
abstract class ScriptFeature {
|
abstract class ScriptFeature {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Collect the Script Features of the given objects
|
* Collect the Script Features of the given objects
|
||||||
*
|
*
|
||||||
* @param ScriptFeatureable $objects (optional) Various amount of ScriptFeatureable objects
|
|
||||||
* @return ScriptFeature[]
|
* @return ScriptFeature[]
|
||||||
*/
|
*/
|
||||||
public static function collect() {
|
public static function collect() {
|
||||||
@ -36,7 +36,7 @@ abstract class ScriptFeature {
|
|||||||
* Prepare the given Script for rendering by adding the needed Labels, etc.
|
* Prepare the given Script for rendering by adding the needed Labels, etc.
|
||||||
*
|
*
|
||||||
* @param Script $script Script to prepare
|
* @param Script $script Script to prepare
|
||||||
* @return \FML\Script\Features\ScriptFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public abstract function prepare(Script $script);
|
public abstract function prepare(Script $script);
|
||||||
}
|
}
|
||||||
|
@ -52,7 +52,7 @@ class Toggle extends ScriptFeature {
|
|||||||
* Set the toggling Control
|
* Set the toggling Control
|
||||||
*
|
*
|
||||||
* @param Control $control Toggling Control
|
* @param Control $control Toggling Control
|
||||||
* @return \FML\Script\Features\Toggle|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTogglingControl(Control $control) {
|
public function setTogglingControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -67,7 +67,7 @@ class Toggle extends ScriptFeature {
|
|||||||
* Set the toggled Control
|
* Set the toggled Control
|
||||||
*
|
*
|
||||||
* @param Control $control Toggling Control
|
* @param Control $control Toggling Control
|
||||||
* @return \FML\Script\Features\Toggle|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setToggledControl(Control $control) {
|
public function setToggledControl(Control $control) {
|
||||||
$this->toggledControl = $control->checkId();
|
$this->toggledControl = $control->checkId();
|
||||||
@ -78,7 +78,7 @@ class Toggle extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label Name
|
* @param string $labelName Script Label Name
|
||||||
* @return \FML\Script\Features\Toggle|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
@ -89,7 +89,7 @@ class Toggle extends ScriptFeature {
|
|||||||
* Set to only show
|
* Set to only show
|
||||||
*
|
*
|
||||||
* @param bool $onlyShow Whether it should only show the Control but not toggle
|
* @param bool $onlyShow Whether it should only show the Control but not toggle
|
||||||
* @return \FML\Script\Features\Toggle|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setOnlyShow($onlyShow) {
|
public function setOnlyShow($onlyShow) {
|
||||||
$this->onlyShow = (bool)$onlyShow;
|
$this->onlyShow = (bool)$onlyShow;
|
||||||
@ -100,7 +100,7 @@ class Toggle extends ScriptFeature {
|
|||||||
* Set to only hide
|
* Set to only hide
|
||||||
*
|
*
|
||||||
* @param bool $onlyHide Whether it should only hide the Control but not toggle
|
* @param bool $onlyHide Whether it should only hide the Control but not toggle
|
||||||
* @return \FML\Script\Features\Toggle|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setOnlyHide($onlyHide) {
|
public function setOnlyHide($onlyHide) {
|
||||||
$this->onlyHide = (bool)$onlyHide;
|
$this->onlyHide = (bool)$onlyHide;
|
||||||
|
@ -55,7 +55,7 @@ class Tooltip extends ScriptFeature {
|
|||||||
* Set the Hover Control
|
* Set the Hover Control
|
||||||
*
|
*
|
||||||
* @param Control $hoverControl Hover Control
|
* @param Control $hoverControl Hover Control
|
||||||
* @return \FML\Script\Features\Tooltip|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setHoverControl(Control $hoverControl) {
|
public function setHoverControl(Control $hoverControl) {
|
||||||
$hoverControl->checkId();
|
$hoverControl->checkId();
|
||||||
@ -70,7 +70,7 @@ class Tooltip extends ScriptFeature {
|
|||||||
* Set the Tooltip Control
|
* Set the Tooltip Control
|
||||||
*
|
*
|
||||||
* @param Control $tooltipControl Tooltip Control
|
* @param Control $tooltipControl Tooltip Control
|
||||||
* @return \FML\Script\Features\Tooltip|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTooltipControl(Control $tooltipControl) {
|
public function setTooltipControl(Control $tooltipControl) {
|
||||||
$this->tooltipControl = $tooltipControl->checkId()->setVisible(false);
|
$this->tooltipControl = $tooltipControl->checkId()->setVisible(false);
|
||||||
@ -81,7 +81,7 @@ class Tooltip extends ScriptFeature {
|
|||||||
* Set to only show
|
* Set to only show
|
||||||
*
|
*
|
||||||
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
* @param bool $stayOnClick (optional) Whether the Tooltip should stay on click
|
||||||
* @return \FML\Script\Features\Tooltip|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStayOnClick($stayOnClick) {
|
public function setStayOnClick($stayOnClick) {
|
||||||
$this->stayOnClick = (bool)$stayOnClick;
|
$this->stayOnClick = (bool)$stayOnClick;
|
||||||
@ -92,7 +92,7 @@ class Tooltip extends ScriptFeature {
|
|||||||
* Set to only hide
|
* Set to only hide
|
||||||
*
|
*
|
||||||
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
* @param bool $invert (optional) Whether the visibility toggling should be inverted
|
||||||
* @return \FML\Script\Features\Tooltip|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setInvert($invert) {
|
public function setInvert($invert) {
|
||||||
$this->invert = (bool)$invert;
|
$this->invert = (bool)$invert;
|
||||||
@ -103,7 +103,7 @@ class Tooltip extends ScriptFeature {
|
|||||||
* Set text
|
* Set text
|
||||||
*
|
*
|
||||||
* @param string $text (optional) Text to display if the TooltipControl is a Label
|
* @param string $text (optional) Text to display if the TooltipControl is a Label
|
||||||
* @return \FML\Script\Features\Tooltip|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
|
@ -82,7 +82,7 @@ class UISound extends ScriptFeature {
|
|||||||
* Set the sound to play
|
* Set the sound to play
|
||||||
*
|
*
|
||||||
* @param string $soundName Sound name
|
* @param string $soundName Sound name
|
||||||
* @return \FML\Script\Features\UISound|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setSoundName($soundName) {
|
public function setSoundName($soundName) {
|
||||||
$this->soundName = (string)$soundName;
|
$this->soundName = (string)$soundName;
|
||||||
@ -93,7 +93,7 @@ class UISound extends ScriptFeature {
|
|||||||
* Set the Control
|
* Set the Control
|
||||||
*
|
*
|
||||||
* @param Control $control Action Control
|
* @param Control $control Action Control
|
||||||
* @return \FML\Script\Features\UISound|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setControl(Control $control) {
|
public function setControl(Control $control) {
|
||||||
$control->checkId();
|
$control->checkId();
|
||||||
@ -108,7 +108,7 @@ class UISound extends ScriptFeature {
|
|||||||
* Set the sound variant
|
* Set the sound variant
|
||||||
*
|
*
|
||||||
* @param int $variant Sound variant
|
* @param int $variant Sound variant
|
||||||
* @return \FML\Script\Features\UISound|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setVariant($variant) {
|
public function setVariant($variant) {
|
||||||
$this->variant = (int)$variant;
|
$this->variant = (int)$variant;
|
||||||
@ -119,7 +119,7 @@ class UISound extends ScriptFeature {
|
|||||||
* Set the volume
|
* Set the volume
|
||||||
*
|
*
|
||||||
* @param float $volume Sound volume
|
* @param float $volume Sound volume
|
||||||
* @return \FML\Script\Features\UISound|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setVolume($volume) {
|
public function setVolume($volume) {
|
||||||
$this->volume = (float)$volume;
|
$this->volume = (float)$volume;
|
||||||
@ -130,7 +130,7 @@ class UISound extends ScriptFeature {
|
|||||||
* Set the label name
|
* Set the label name
|
||||||
*
|
*
|
||||||
* @param string $labelName Script Label name
|
* @param string $labelName Script Label name
|
||||||
* @return \FML\Script\Features\UISound|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabelName($labelName) {
|
public function setLabelName($labelName) {
|
||||||
$this->labelName = (string)$labelName;
|
$this->labelName = (string)$labelName;
|
||||||
|
@ -62,7 +62,7 @@ class ValuePickerFeature extends ScriptFeature {
|
|||||||
* Set the ValuePicker Label
|
* Set the ValuePicker Label
|
||||||
*
|
*
|
||||||
* @param Label $label ValuePicker Label
|
* @param Label $label ValuePicker Label
|
||||||
* @return \FML\Script\Features\ValuePickerFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLabel(Label $label) {
|
public function setLabel(Label $label) {
|
||||||
$this->label = $label->checkId()->setScriptEvents(true);
|
$this->label = $label->checkId()->setScriptEvents(true);
|
||||||
@ -82,7 +82,7 @@ class ValuePickerFeature extends ScriptFeature {
|
|||||||
* Set the hidden Entry
|
* Set the hidden Entry
|
||||||
*
|
*
|
||||||
* @param Entry $entry Hidden Entry
|
* @param Entry $entry Hidden Entry
|
||||||
* @return \FML\Script\Features\ValuePickerFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setEntry(Entry $entry) {
|
public function setEntry(Entry $entry) {
|
||||||
$this->entry = $entry->checkId();
|
$this->entry = $entry->checkId();
|
||||||
@ -102,7 +102,7 @@ class ValuePickerFeature extends ScriptFeature {
|
|||||||
* Set the possible values
|
* Set the possible values
|
||||||
*
|
*
|
||||||
* @param array $values Possible values
|
* @param array $values Possible values
|
||||||
* @return \FML\Script\Features\ValuePickerFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setValues(array $values) {
|
public function setValues(array $values) {
|
||||||
$this->values = array();
|
$this->values = array();
|
||||||
@ -116,7 +116,7 @@ class ValuePickerFeature extends ScriptFeature {
|
|||||||
* Set the default value
|
* Set the default value
|
||||||
*
|
*
|
||||||
* @param string $default Default value
|
* @param string $default Default value
|
||||||
* @return \FML\Script\Features\ValuePickerFeature|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDefault($default) {
|
public function setDefault($default) {
|
||||||
$this->default = (string)$default;
|
$this->default = (string)$default;
|
||||||
|
@ -36,7 +36,7 @@ class Script {
|
|||||||
*
|
*
|
||||||
* @param string $file Include file
|
* @param string $file Include file
|
||||||
* @param string $namespace Include namespace
|
* @param string $namespace Include namespace
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setScriptInclude($file, $namespace = null) {
|
public function setScriptInclude($file, $namespace = null) {
|
||||||
if (is_object($file) && ($file instanceof ScriptInclude)) {
|
if (is_object($file) && ($file instanceof ScriptInclude)) {
|
||||||
@ -53,7 +53,7 @@ class Script {
|
|||||||
*
|
*
|
||||||
* @param string $name Constant name
|
* @param string $name Constant name
|
||||||
* @param string $value Constant value
|
* @param string $value Constant value
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addScriptConstant($name, $value = null) {
|
public function addScriptConstant($name, $value = null) {
|
||||||
if (is_object($name) && ($name instanceof ScriptConstant)) {
|
if (is_object($name) && ($name instanceof ScriptConstant)) {
|
||||||
@ -72,7 +72,7 @@ class Script {
|
|||||||
*
|
*
|
||||||
* @param string $name Function name
|
* @param string $name Function name
|
||||||
* @param string $text Function text
|
* @param string $text Function text
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addScriptFunction($name, $text = null) {
|
public function addScriptFunction($name, $text = null) {
|
||||||
if (is_object($name) && ($name instanceof ScriptFunction)) {
|
if (is_object($name) && ($name instanceof ScriptFunction)) {
|
||||||
@ -91,7 +91,7 @@ class Script {
|
|||||||
*
|
*
|
||||||
* @param string $name Label name
|
* @param string $name Label name
|
||||||
* @param string $text Script text
|
* @param string $text Script text
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addCustomScriptLabel($name, $text = null) {
|
public function addCustomScriptLabel($name, $text = null) {
|
||||||
if (is_object($name) && ($name instanceof ScriptLabel)) {
|
if (is_object($name) && ($name instanceof ScriptLabel)) {
|
||||||
@ -109,7 +109,7 @@ class Script {
|
|||||||
* @param string $name Label name
|
* @param string $name Label name
|
||||||
* @param string $text Script text
|
* @param string $text Script text
|
||||||
* @param bool $isolated (optional) Whether to isolate the Label Script
|
* @param bool $isolated (optional) Whether to isolate the Label Script
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function appendGenericScriptLabel($name, $text = null, $isolated = false) {
|
public function appendGenericScriptLabel($name, $text = null, $isolated = false) {
|
||||||
if (is_object($name) && ($name instanceof ScriptLabel)) {
|
if (is_object($name) && ($name instanceof ScriptLabel)) {
|
||||||
@ -124,7 +124,7 @@ class Script {
|
|||||||
/**
|
/**
|
||||||
* Remove all generic Script texts
|
* Remove all generic Script texts
|
||||||
*
|
*
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function resetGenericScriptLabels() {
|
public function resetGenericScriptLabels() {
|
||||||
$this->genericLabels = array();
|
$this->genericLabels = array();
|
||||||
@ -135,7 +135,7 @@ class Script {
|
|||||||
* Add a Script Feature
|
* Add a Script Feature
|
||||||
*
|
*
|
||||||
* @param ScriptFeature $feature Script Feature
|
* @param ScriptFeature $feature Script Feature
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addFeature(ScriptFeature $feature) {
|
public function addFeature(ScriptFeature $feature) {
|
||||||
if (!in_array($feature, $this->features, true)) {
|
if (!in_array($feature, $this->features, true)) {
|
||||||
@ -148,7 +148,7 @@ class Script {
|
|||||||
* Load the given Script Feature
|
* Load the given Script Feature
|
||||||
*
|
*
|
||||||
* @param ScriptFeature $scriptFeature Script Feature to load
|
* @param ScriptFeature $scriptFeature Script Feature to load
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function loadFeature(ScriptFeature $scriptFeature) {
|
public function loadFeature(ScriptFeature $scriptFeature) {
|
||||||
$scriptFeature->prepare($this);
|
$scriptFeature->prepare($this);
|
||||||
@ -159,7 +159,7 @@ class Script {
|
|||||||
* Load the given Script Features
|
* Load the given Script Features
|
||||||
*
|
*
|
||||||
* @param ScriptFeature[] $scriptFeatures Script Features to load
|
* @param ScriptFeature[] $scriptFeatures Script Features to load
|
||||||
* @return \FML\Script\Script|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function loadFeatures(array $scriptFeatures) {
|
public function loadFeatures(array $scriptFeatures) {
|
||||||
foreach ($scriptFeatures as $scriptFeature) {
|
foreach ($scriptFeatures as $scriptFeature) {
|
||||||
|
@ -31,7 +31,7 @@ class ScriptConstant {
|
|||||||
* Set the name
|
* Set the name
|
||||||
*
|
*
|
||||||
* @param string $name Constant name
|
* @param string $name Constant name
|
||||||
* @return \FML\Script\ScriptConstant|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -42,7 +42,7 @@ class ScriptConstant {
|
|||||||
* Set the value
|
* Set the value
|
||||||
*
|
*
|
||||||
* @param string $value Constant value
|
* @param string $value Constant value
|
||||||
* @return \FML\Script\ScriptConstant|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setValue($value) {
|
public function setValue($value) {
|
||||||
$this->value = $value;
|
$this->value = $value;
|
||||||
|
@ -31,7 +31,7 @@ class ScriptFunction {
|
|||||||
* Set the name
|
* Set the name
|
||||||
*
|
*
|
||||||
* @param string $name Function name
|
* @param string $name Function name
|
||||||
* @return \FML\Script\ScriptFunction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -42,7 +42,7 @@ class ScriptFunction {
|
|||||||
* Set the text
|
* Set the text
|
||||||
*
|
*
|
||||||
* @param string $text Function text
|
* @param string $text Function text
|
||||||
* @return \FML\Script\ScriptFunction|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
|
@ -37,7 +37,7 @@ class ScriptInclude {
|
|||||||
* Set the file
|
* Set the file
|
||||||
*
|
*
|
||||||
* @param string $file Include file
|
* @param string $file Include file
|
||||||
* @return \FML\Script\ScriptInclude|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFile($file) {
|
public function setFile($file) {
|
||||||
$this->file = (string)$file;
|
$this->file = (string)$file;
|
||||||
@ -48,7 +48,7 @@ class ScriptInclude {
|
|||||||
* Set the namespace
|
* Set the namespace
|
||||||
*
|
*
|
||||||
* @param string $namespace Include namespace
|
* @param string $namespace Include namespace
|
||||||
* @return \FML\Script\ScriptInclude|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setNamespace($namespace) {
|
public function setNamespace($namespace) {
|
||||||
$this->namespace = (string)$namespace;
|
$this->namespace = (string)$namespace;
|
||||||
|
@ -46,7 +46,7 @@ class ScriptLabel {
|
|||||||
* Set the name
|
* Set the name
|
||||||
*
|
*
|
||||||
* @param string $name Label name
|
* @param string $name Label name
|
||||||
* @return \FML\Script\ScriptLabel|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setName($name) {
|
public function setName($name) {
|
||||||
$this->name = (string)$name;
|
$this->name = (string)$name;
|
||||||
@ -57,7 +57,7 @@ class ScriptLabel {
|
|||||||
* Set the text
|
* Set the text
|
||||||
*
|
*
|
||||||
* @param string $text Script text
|
* @param string $text Script text
|
||||||
* @return \FML\Script\ScriptLabel|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setText($text) {
|
public function setText($text) {
|
||||||
$this->text = (string)$text;
|
$this->text = (string)$text;
|
||||||
@ -68,7 +68,7 @@ class ScriptLabel {
|
|||||||
* Set isolation
|
* Set isolation
|
||||||
*
|
*
|
||||||
* @param bool $isolated Whether the code should be isolated in an own block
|
* @param bool $isolated Whether the code should be isolated in an own block
|
||||||
* @return \FML\Script\ScriptLabel|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setIsolated($isolated) {
|
public function setIsolated($isolated) {
|
||||||
$this->isolated = (bool)$isolated;
|
$this->isolated = (bool)$isolated;
|
||||||
|
@ -35,7 +35,7 @@ class Mood {
|
|||||||
/**
|
/**
|
||||||
* Create a new Mood object
|
* Create a new Mood object
|
||||||
*
|
*
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -47,7 +47,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLightAmbientColor($red, $green, $blue) {
|
public function setLightAmbientColor($red, $green, $blue) {
|
||||||
$this->lAmbient_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->lAmbient_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -60,7 +60,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCloudsColorMin($red, $green, $blue) {
|
public function setCloudsColorMin($red, $green, $blue) {
|
||||||
$this->cloudsRgbMinLinear = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->cloudsRgbMinLinear = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -73,7 +73,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setCloudsColorMax($red, $green, $blue) {
|
public function setCloudsColorMax($red, $green, $blue) {
|
||||||
$this->cloudsRgbMaxLinear = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->cloudsRgbMaxLinear = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -86,7 +86,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLight0Color($red, $green, $blue) {
|
public function setLight0Color($red, $green, $blue) {
|
||||||
$this->lDir0_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->lDir0_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -97,7 +97,7 @@ class Mood {
|
|||||||
* Set intensity of light source 0
|
* Set intensity of light source 0
|
||||||
*
|
*
|
||||||
* @param float $intensity Light intensity
|
* @param float $intensity Light intensity
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLight0Intensity($intensity) {
|
public function setLight0Intensity($intensity) {
|
||||||
$this->lDir0_Intens = (float)$intensity;
|
$this->lDir0_Intens = (float)$intensity;
|
||||||
@ -108,7 +108,7 @@ class Mood {
|
|||||||
* Set phi angle of light source 0
|
* Set phi angle of light source 0
|
||||||
*
|
*
|
||||||
* @param float $phiAngle Phi angle
|
* @param float $phiAngle Phi angle
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLight0PhiAngle($phiAngle) {
|
public function setLight0PhiAngle($phiAngle) {
|
||||||
$this->lDir0_DirPhi = (float)$phiAngle;
|
$this->lDir0_DirPhi = (float)$phiAngle;
|
||||||
@ -119,7 +119,7 @@ class Mood {
|
|||||||
* Set theta angle of light source 0
|
* Set theta angle of light source 0
|
||||||
*
|
*
|
||||||
* @param float $thetaAngle Theta angle
|
* @param float $thetaAngle Theta angle
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLight0ThetaAngle($thetaAngle) {
|
public function setLight0ThetaAngle($thetaAngle) {
|
||||||
$this->lDir0_DirTheta = (float)$thetaAngle;
|
$this->lDir0_DirTheta = (float)$thetaAngle;
|
||||||
@ -132,7 +132,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLightBallColor($red, $green, $blue) {
|
public function setLightBallColor($red, $green, $blue) {
|
||||||
$this->lBall_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->lBall_LinearRgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -143,7 +143,7 @@ class Mood {
|
|||||||
* Set light ball intensity
|
* Set light ball intensity
|
||||||
*
|
*
|
||||||
* @param float $intensity Light ball intensity
|
* @param float $intensity Light ball intensity
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLightBallIntensity($intensity) {
|
public function setLightBallIntensity($intensity) {
|
||||||
$this->lBall_Intensity = (float)$intensity;
|
$this->lBall_Intensity = (float)$intensity;
|
||||||
@ -154,7 +154,7 @@ class Mood {
|
|||||||
* Set light ball radius
|
* Set light ball radius
|
||||||
*
|
*
|
||||||
* @param float $radius Light ball radius
|
* @param float $radius Light ball radius
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLightBallRadius($radius) {
|
public function setLightBallRadius($radius) {
|
||||||
$this->lBall_Radius = (float)$radius;
|
$this->lBall_Radius = (float)$radius;
|
||||||
@ -167,7 +167,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFogColor($red, $green, $blue) {
|
public function setFogColor($red, $green, $blue) {
|
||||||
$this->fogColorSrgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->fogColorSrgb = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -180,7 +180,7 @@ class Mood {
|
|||||||
* @param float $red Red color value
|
* @param float $red Red color value
|
||||||
* @param float $green Green color value
|
* @param float $green Green color value
|
||||||
* @param float $blue Blue color value
|
* @param float $blue Blue color value
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setSelfIllumColor($red, $green, $blue) {
|
public function setSelfIllumColor($red, $green, $blue) {
|
||||||
$this->selfIllumColor = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
$this->selfIllumColor = floatval($red) . ' ' . floatval($green) . ' ' . floatval($blue);
|
||||||
@ -191,7 +191,7 @@ class Mood {
|
|||||||
* Set sky gradient scale
|
* Set sky gradient scale
|
||||||
*
|
*
|
||||||
* @param float $scale Gradient scale
|
* @param float $scale Gradient scale
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setSkyGradientScale($scale) {
|
public function setSkyGradientScale($scale) {
|
||||||
$this->skyGradientV_Scale = (float)$scale;
|
$this->skyGradientV_Scale = (float)$scale;
|
||||||
@ -203,7 +203,7 @@ class Mood {
|
|||||||
*
|
*
|
||||||
* @param float $gradientX Scale value
|
* @param float $gradientX Scale value
|
||||||
* @param string $color Gradient color
|
* @param string $color Gradient color
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addSkyGradientKey($gradientX, $color) {
|
public function addSkyGradientKey($gradientX, $color) {
|
||||||
$gradientX = (float)$gradientX;
|
$gradientX = (float)$gradientX;
|
||||||
@ -216,7 +216,7 @@ class Mood {
|
|||||||
/**
|
/**
|
||||||
* Remove all sky gradient keys
|
* Remove all sky gradient keys
|
||||||
*
|
*
|
||||||
* @return \FML\Stylesheet\Mood|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeSkyGradientKeys() {
|
public function removeSkyGradientKeys() {
|
||||||
$this->skyGradientKeys = array();
|
$this->skyGradientKeys = array();
|
||||||
|
@ -41,7 +41,7 @@ class Style3d {
|
|||||||
* Create a new Style3d object
|
* Create a new Style3d object
|
||||||
*
|
*
|
||||||
* @param string $styleId (optional) Style id
|
* @param string $styleId (optional) Style id
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create($styleId = null) {
|
public static function create($styleId = null) {
|
||||||
return new static($styleId);
|
return new static($styleId);
|
||||||
@ -62,7 +62,7 @@ class Style3d {
|
|||||||
* Set style id
|
* Set style id
|
||||||
*
|
*
|
||||||
* @param string $styleId Style id
|
* @param string $styleId Style id
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setId($styleId) {
|
public function setId($styleId) {
|
||||||
$this->styleId = (string)$styleId;
|
$this->styleId = (string)$styleId;
|
||||||
@ -72,7 +72,7 @@ class Style3d {
|
|||||||
/**
|
/**
|
||||||
* Check for id and assign one if necessary
|
* Check for id and assign one if necessary
|
||||||
*
|
*
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function checkId() {
|
public function checkId() {
|
||||||
if (!$this->styleId) {
|
if (!$this->styleId) {
|
||||||
@ -94,7 +94,7 @@ class Style3d {
|
|||||||
* Set model
|
* Set model
|
||||||
*
|
*
|
||||||
* @param string $model Style model
|
* @param string $model Style model
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setModel($model) {
|
public function setModel($model) {
|
||||||
$this->model = (string)$model;
|
$this->model = (string)$model;
|
||||||
@ -105,7 +105,7 @@ class Style3d {
|
|||||||
* Set thickness
|
* Set thickness
|
||||||
*
|
*
|
||||||
* @param float $thickness Style thickness
|
* @param float $thickness Style thickness
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setThickness($thickness) {
|
public function setThickness($thickness) {
|
||||||
$this->thickness = (float)$thickness;
|
$this->thickness = (float)$thickness;
|
||||||
@ -116,7 +116,7 @@ class Style3d {
|
|||||||
* Set color
|
* Set color
|
||||||
*
|
*
|
||||||
* @param string $color Style color
|
* @param string $color Style color
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setColor($color) {
|
public function setColor($color) {
|
||||||
$this->color = (string)$color;
|
$this->color = (string)$color;
|
||||||
@ -127,7 +127,7 @@ class Style3d {
|
|||||||
* Set focus color
|
* Set focus color
|
||||||
*
|
*
|
||||||
* @param string $focusColor Style focus color
|
* @param string $focusColor Style focus color
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFocusColor($focusColor) {
|
public function setFocusColor($focusColor) {
|
||||||
$this->focusColor = (string)$focusColor;
|
$this->focusColor = (string)$focusColor;
|
||||||
@ -138,7 +138,7 @@ class Style3d {
|
|||||||
* Set light color
|
* Set light color
|
||||||
*
|
*
|
||||||
* @param string $lightColor Light color
|
* @param string $lightColor Light color
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLightColor($lightColor) {
|
public function setLightColor($lightColor) {
|
||||||
$this->lightColor = (string)$lightColor;
|
$this->lightColor = (string)$lightColor;
|
||||||
@ -149,7 +149,7 @@ class Style3d {
|
|||||||
* Set focus light color
|
* Set focus light color
|
||||||
*
|
*
|
||||||
* @param string $focusLightColor Focus light color
|
* @param string $focusLightColor Focus light color
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFocusLightColor($focusLightColor) {
|
public function setFocusLightColor($focusLightColor) {
|
||||||
$this->focusLightColor = (string)$focusLightColor;
|
$this->focusLightColor = (string)$focusLightColor;
|
||||||
@ -160,7 +160,7 @@ class Style3d {
|
|||||||
* Set Y-offset
|
* Set Y-offset
|
||||||
*
|
*
|
||||||
* @param float $yOffset Y-offset
|
* @param float $yOffset Y-offset
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setYOffset($yOffset) {
|
public function setYOffset($yOffset) {
|
||||||
$this->yOffset = (float)$yOffset;
|
$this->yOffset = (float)$yOffset;
|
||||||
@ -171,7 +171,7 @@ class Style3d {
|
|||||||
* Set focus Y-offset
|
* Set focus Y-offset
|
||||||
*
|
*
|
||||||
* @param float $focusYOffset Focus Y-offset
|
* @param float $focusYOffset Focus Y-offset
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFocusYOffset($focusYOffset) {
|
public function setFocusYOffset($focusYOffset) {
|
||||||
$this->focusYOffset = (float)$focusYOffset;
|
$this->focusYOffset = (float)$focusYOffset;
|
||||||
@ -182,7 +182,7 @@ class Style3d {
|
|||||||
* Set Z-offset
|
* Set Z-offset
|
||||||
*
|
*
|
||||||
* @param float $zOffset Z-offset
|
* @param float $zOffset Z-offset
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setZOffset($zOffset) {
|
public function setZOffset($zOffset) {
|
||||||
$this->zOffset = (float)$zOffset;
|
$this->zOffset = (float)$zOffset;
|
||||||
@ -193,7 +193,7 @@ class Style3d {
|
|||||||
* Set focus Z-offset
|
* Set focus Z-offset
|
||||||
*
|
*
|
||||||
* @param float $focusZOffset Focus Z-offset
|
* @param float $focusZOffset Focus Z-offset
|
||||||
* @return \FML\Stylesheet\Style3d|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFocusZOffset($focusZOffset) {
|
public function setFocusZOffset($focusZOffset) {
|
||||||
$this->focusZOffset = (float)$focusZOffset;
|
$this->focusZOffset = (float)$focusZOffset;
|
||||||
|
@ -22,7 +22,7 @@ class Stylesheet {
|
|||||||
/**
|
/**
|
||||||
* Create a new Stylesheet object
|
* Create a new Stylesheet object
|
||||||
*
|
*
|
||||||
* @return \FML\Stylesheet\Stylesheet|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
@ -32,7 +32,7 @@ class Stylesheet {
|
|||||||
* Add a new Style3d
|
* Add a new Style3d
|
||||||
*
|
*
|
||||||
* @param Style3d $style3d Style3d object
|
* @param Style3d $style3d Style3d object
|
||||||
* @return \FML\Stylesheet\Stylesheet|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function addStyle3d(Style3d $style3d) {
|
public function addStyle3d(Style3d $style3d) {
|
||||||
if (!in_array($style3d, $this->styles3d, true)) {
|
if (!in_array($style3d, $this->styles3d, true)) {
|
||||||
@ -44,7 +44,7 @@ class Stylesheet {
|
|||||||
/**
|
/**
|
||||||
* Remove all Style3ds
|
* Remove all Style3ds
|
||||||
*
|
*
|
||||||
* @return \FML\Stylesheet\Stylesheet|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeStyles() {
|
public function removeStyles() {
|
||||||
$this->styles3d = array();
|
$this->styles3d = array();
|
||||||
@ -55,7 +55,7 @@ class Stylesheet {
|
|||||||
* Set the Mood object of the Stylesheet
|
* Set the Mood object of the Stylesheet
|
||||||
*
|
*
|
||||||
* @param Mood $mood Mood object
|
* @param Mood $mood Mood object
|
||||||
* @return \FML\Stylesheet\Stylesheet|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setMood(Mood $mood) {
|
public function setMood(Mood $mood) {
|
||||||
$this->mood = $mood;
|
$this->mood = $mood;
|
||||||
|
@ -36,7 +36,7 @@ interface Actionable {
|
|||||||
* Set action
|
* Set action
|
||||||
*
|
*
|
||||||
* @param string $action Action name
|
* @param string $action Action name
|
||||||
* @return \FML\Types\Actionable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAction($action);
|
public function setAction($action);
|
||||||
|
|
||||||
@ -51,7 +51,7 @@ interface Actionable {
|
|||||||
* Set action key
|
* Set action key
|
||||||
*
|
*
|
||||||
* @param int $actionKey Action key
|
* @param int $actionKey Action key
|
||||||
* @return \FML\Types\Actionable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setActionKey($actionKey);
|
public function setActionKey($actionKey);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface BgColorable {
|
|||||||
* Set background color
|
* Set background color
|
||||||
*
|
*
|
||||||
* @param string $bgColor Background color
|
* @param string $bgColor Background color
|
||||||
* @return \FML\Types\BgColorable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setBgColor($bgColor);
|
public function setBgColor($bgColor);
|
||||||
}
|
}
|
||||||
|
@ -17,14 +17,14 @@ interface Container {
|
|||||||
* Add a new child Element
|
* Add a new child Element
|
||||||
*
|
*
|
||||||
* @param Renderable $child Child Control to add
|
* @param Renderable $child Child Control to add
|
||||||
* @return \FML\Types\Container|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function add(Renderable $child);
|
public function add(Renderable $child);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Remove all children
|
* Remove all children
|
||||||
*
|
*
|
||||||
* @return \FML\Types\Container|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function removeChildren();
|
public function removeChildren();
|
||||||
|
|
||||||
@ -32,7 +32,7 @@ interface Container {
|
|||||||
* Set the Format object of the Container
|
* Set the Format object of the Container
|
||||||
*
|
*
|
||||||
* @param Format $format New Format object
|
* @param Format $format New Format object
|
||||||
* @return \FML\Types\Container|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setFormat(Format $format);
|
public function setFormat(Format $format);
|
||||||
|
|
||||||
@ -40,7 +40,7 @@ interface Container {
|
|||||||
* Get the Format object of the Container
|
* Get the Format object of the Container
|
||||||
*
|
*
|
||||||
* @param bool $createIfEmpty (optional) Whether the Format object should be created if it's not set
|
* @param bool $createIfEmpty (optional) Whether the Format object should be created if it's not set
|
||||||
* @return \FML\Elements\Format|static
|
* @return \FML\Elements\Format
|
||||||
*/
|
*/
|
||||||
public function getFormat($createIfEmpty = true);
|
public function getFormat($createIfEmpty = true);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface Linkable {
|
|||||||
* Set url
|
* Set url
|
||||||
*
|
*
|
||||||
* @param string $url Link url
|
* @param string $url Link url
|
||||||
* @return \FML\Types\Linkable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrl($url);
|
public function setUrl($url);
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ interface Linkable {
|
|||||||
* Set url id to use from Dico
|
* Set url id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $urlId Url id
|
* @param string $urlId Url id
|
||||||
* @return \FML\Types\Linkable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setUrlId($urlId);
|
public function setUrlId($urlId);
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ interface Linkable {
|
|||||||
* Set manialink
|
* Set manialink
|
||||||
*
|
*
|
||||||
* @param string $manialink Manialink name
|
* @param string $manialink Manialink name
|
||||||
* @return \FML\Types\Linkable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setManialink($manialink);
|
public function setManialink($manialink);
|
||||||
|
|
||||||
@ -39,7 +39,7 @@ interface Linkable {
|
|||||||
* Set manialink id to use from Dico
|
* Set manialink id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $manialinkId Manialink id
|
* @param string $manialinkId Manialink id
|
||||||
* @return \FML\Types\Linkable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setManialinkId($manialinkId);
|
public function setManialinkId($manialinkId);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface NewLineable {
|
|||||||
* Set auto new line
|
* Set auto new line
|
||||||
*
|
*
|
||||||
* @param bool $autoNewLine Whether the Control should insert new lines automatically
|
* @param bool $autoNewLine Whether the Control should insert new lines automatically
|
||||||
* @return \FML\Types\NewLineable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAutoNewLine($autoNewLine);
|
public function setAutoNewLine($autoNewLine);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface Playable {
|
|||||||
* Set data
|
* Set data
|
||||||
*
|
*
|
||||||
* @param string $data Media url
|
* @param string $data Media url
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setData($data);
|
public function setData($data);
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ interface Playable {
|
|||||||
* Set data id to use from Dico
|
* Set data id to use from Dico
|
||||||
*
|
*
|
||||||
* @param string $dataId Data id
|
* @param string $dataId Data id
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setDataId($dataId);
|
public function setDataId($dataId);
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ interface Playable {
|
|||||||
* Set play
|
* Set play
|
||||||
*
|
*
|
||||||
* @param bool $play Whether the Control should start playing automatically
|
* @param bool $play Whether the Control should start playing automatically
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setPlay($play);
|
public function setPlay($play);
|
||||||
|
|
||||||
@ -39,7 +39,7 @@ interface Playable {
|
|||||||
* Set looping
|
* Set looping
|
||||||
*
|
*
|
||||||
* @param bool $looping Whether the Control should play looping
|
* @param bool $looping Whether the Control should play looping
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setLooping($looping);
|
public function setLooping($looping);
|
||||||
|
|
||||||
@ -47,7 +47,7 @@ interface Playable {
|
|||||||
* Set music
|
* Set music
|
||||||
*
|
*
|
||||||
* @param bool $music Whether the Control represents background music
|
* @param bool $music Whether the Control represents background music
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setMusic($music);
|
public function setMusic($music);
|
||||||
|
|
||||||
@ -55,7 +55,7 @@ interface Playable {
|
|||||||
* Set volume
|
* Set volume
|
||||||
*
|
*
|
||||||
* @param float $volume Media volume
|
* @param float $volume Media volume
|
||||||
* @return \FML\Types\Playable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setVolume($volume);
|
public function setVolume($volume);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface Scriptable {
|
|||||||
* Set script events
|
* Set script events
|
||||||
*
|
*
|
||||||
* @param bool $scriptEvents Whether script events should be enabled
|
* @param bool $scriptEvents Whether script events should be enabled
|
||||||
* @return \FML\Types\Scriptable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setScriptEvents($scriptEvents);
|
public function setScriptEvents($scriptEvents);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface Styleable {
|
|||||||
* Set style
|
* Set style
|
||||||
*
|
*
|
||||||
* @param string $style Style name
|
* @param string $style Style name
|
||||||
* @return \FML\Types\Styleable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStyle($style);
|
public function setStyle($style);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface SubStyleable {
|
|||||||
* Set sub style
|
* Set sub style
|
||||||
*
|
*
|
||||||
* @param string $subStyle SubStyle name
|
* @param string $subStyle SubStyle name
|
||||||
* @return \FML\Types\SubStyleable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setSubStyle($subStyle);
|
public function setSubStyle($subStyle);
|
||||||
|
|
||||||
@ -24,7 +24,7 @@ interface SubStyleable {
|
|||||||
*
|
*
|
||||||
* @param string $style Style name
|
* @param string $style Style name
|
||||||
* @param string $subStyle SubStyle name
|
* @param string $subStyle SubStyle name
|
||||||
* @return \FML\Types\SubStyleable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setStyles($style, $subStyle);
|
public function setStyles($style, $subStyle);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ interface TextFormatable {
|
|||||||
* Set text size
|
* Set text size
|
||||||
*
|
*
|
||||||
* @param int $textSize Text size
|
* @param int $textSize Text size
|
||||||
* @return \FML\Types\TextFormatable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTextSize($textSize);
|
public function setTextSize($textSize);
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ interface TextFormatable {
|
|||||||
* Set text color
|
* Set text color
|
||||||
*
|
*
|
||||||
* @param string $textColor Text color
|
* @param string $textColor Text color
|
||||||
* @return \FML\Types\TextFormatable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setTextColor($textColor);
|
public function setTextColor($textColor);
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ interface TextFormatable {
|
|||||||
* Set area color
|
* Set area color
|
||||||
*
|
*
|
||||||
* @param string $areaColor Area color
|
* @param string $areaColor Area color
|
||||||
* @return \FML\Types\TextFormatable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAreaColor($areaColor);
|
public function setAreaColor($areaColor);
|
||||||
|
|
||||||
@ -39,7 +39,7 @@ interface TextFormatable {
|
|||||||
* Set area focus color
|
* Set area focus color
|
||||||
*
|
*
|
||||||
* @param string $areaFocusColor Area focus color
|
* @param string $areaFocusColor Area focus color
|
||||||
* @return \FML\Types\TextFormatable|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function setAreaFocusColor($areaFocusColor);
|
public function setAreaFocusColor($areaFocusColor);
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,7 @@ class UniqueID {
|
|||||||
/**
|
/**
|
||||||
* Create a new Unique ID object
|
* Create a new Unique ID object
|
||||||
*
|
*
|
||||||
* @return \FML\UniqueID|static
|
* @return static
|
||||||
*/
|
*/
|
||||||
public static function create() {
|
public static function create() {
|
||||||
return new static();
|
return new static();
|
||||||
|
Loading…
Reference in New Issue
Block a user