@@ -12,8 +12,9 @@ discard block |
||
12 | 12 | $image=new HtmlImg("img-", $src, $alt); |
13 | 13 | $image->setClass(""); |
14 | 14 | parent::__construct($identifier, "div", "ui image", $image); |
15 | - if (isset($size)) |
|
16 | - $this->setSize($size); |
|
15 | + if (isset($size)) { |
|
16 | + $this->setSize($size); |
|
17 | + } |
|
17 | 18 | } |
18 | 19 | |
19 | 20 | public function setCircular() { |
@@ -21,8 +22,9 @@ discard block |
||
21 | 22 | } |
22 | 23 | |
23 | 24 | public function asAvatar($caption=NULL) { |
24 | - if (isset($caption)) |
|
25 | - $this->wrap("", $caption); |
|
25 | + if (isset($caption)) { |
|
26 | + $this->wrap("", $caption); |
|
27 | + } |
|
26 | 28 | return $this->addToProperty("class", "avatar"); |
27 | 29 | } |
28 | 30 |
@@ -10,64 +10,64 @@ |
||
10 | 10 | |
11 | 11 | class HtmlReveal extends HtmlSemDoubleElement { |
12 | 12 | |
13 | - public function __construct($identifier, $visibleContent,$hiddenContent,$type=RevealType::FADE,$attributeType=NULL) { |
|
13 | + public function __construct($identifier, $visibleContent, $hiddenContent, $type=RevealType::FADE, $attributeType=NULL) { |
|
14 | 14 | parent::__construct($identifier, "div", "ui reveal"); |
15 | 15 | $this->setElement(0, $visibleContent); |
16 | 16 | $this->setElement(1, $hiddenContent); |
17 | - $this->setType($type,$attributeType); |
|
17 | + $this->setType($type, $attributeType); |
|
18 | 18 | } |
19 | 19 | |
20 | - private function setElement($index,$content){ |
|
21 | - if(!$content instanceof HtmlSingleElement){ |
|
22 | - $content=new HtmlLabel("",$content); |
|
20 | + private function setElement($index, $content) { |
|
21 | + if (!$content instanceof HtmlSingleElement) { |
|
22 | + $content=new HtmlLabel("", $content); |
|
23 | 23 | } |
24 | - if($content instanceof HtmlSemDoubleElement){ |
|
25 | - $content=new HtmlSemDoubleElement($this->identifier."-".$index,"div","",$content); |
|
26 | - }elseif ($content instanceof HtmlImg){ |
|
24 | + if ($content instanceof HtmlSemDoubleElement) { |
|
25 | + $content=new HtmlSemDoubleElement($this->identifier."-".$index, "div", "", $content); |
|
26 | + }elseif ($content instanceof HtmlImg) { |
|
27 | 27 | $this->addToPropertyCtrl("class", "image", array("image")); |
28 | 28 | } |
29 | - $content->addToProperty("class",(($index===0)?"visible":"hidden")." content"); |
|
29 | + $content->addToProperty("class", (($index===0) ? "visible" : "hidden")." content"); |
|
30 | 30 | $this->content[$index]=$content; |
31 | 31 | return $this; |
32 | 32 | } |
33 | 33 | |
34 | - public function setVisibleContent($visibleContent){ |
|
34 | + public function setVisibleContent($visibleContent) { |
|
35 | 35 | return $this->setElement(0, $visibleContent); |
36 | 36 | } |
37 | 37 | |
38 | - public function setHiddenContent($hiddenContent){ |
|
38 | + public function setHiddenContent($hiddenContent) { |
|
39 | 39 | return $this->setElement(1, $hiddenContent); |
40 | 40 | } |
41 | 41 | |
42 | - public function getVisibleContent(){ |
|
42 | + public function getVisibleContent() { |
|
43 | 43 | return $this->content[0]; |
44 | 44 | } |
45 | 45 | |
46 | - public function getHiddenContent(){ |
|
46 | + public function getHiddenContent() { |
|
47 | 47 | return $this->content[1]; |
48 | 48 | } |
49 | 49 | |
50 | - public function setType($type,$attribute=NULL){ |
|
50 | + public function setType($type, $attribute=NULL) { |
|
51 | 51 | $this->addToPropertyCtrl("class", $type, RevealType::getConstants()); |
52 | - if(isset($attribute)){ |
|
52 | + if (isset($attribute)) { |
|
53 | 53 | $this->addToPropertyCtrl("class", $attribute, Direction::getConstants()); |
54 | 54 | } |
55 | 55 | return $this; |
56 | 56 | } |
57 | 57 | |
58 | - public function setFade($attribute=NULL){ |
|
59 | - return $this->setType(RevealType::FADE,$attribute); |
|
58 | + public function setFade($attribute=NULL) { |
|
59 | + return $this->setType(RevealType::FADE, $attribute); |
|
60 | 60 | } |
61 | 61 | |
62 | - public function setMove($attribute=NULL){ |
|
63 | - return $this->setType(RevealType::MOVE,$attribute); |
|
62 | + public function setMove($attribute=NULL) { |
|
63 | + return $this->setType(RevealType::MOVE, $attribute); |
|
64 | 64 | } |
65 | 65 | |
66 | - public function setRotate($attribute=NULL){ |
|
67 | - return $this->setType(RevealType::ROTATE,$attribute); |
|
66 | + public function setRotate($attribute=NULL) { |
|
67 | + return $this->setType(RevealType::ROTATE, $attribute); |
|
68 | 68 | } |
69 | 69 | |
70 | - public function setCircular(){ |
|
70 | + public function setCircular() { |
|
71 | 71 | return $this->addToProperty("class", "circular"); |
72 | 72 | } |
73 | 73 |
@@ -23,7 +23,7 @@ |
||
23 | 23 | } |
24 | 24 | if($content instanceof HtmlSemDoubleElement){ |
25 | 25 | $content=new HtmlSemDoubleElement($this->identifier."-".$index,"div","",$content); |
26 | - }elseif ($content instanceof HtmlImg){ |
|
26 | + } elseif ($content instanceof HtmlImg){ |
|
27 | 27 | $this->addToPropertyCtrl("class", "image", array("image")); |
28 | 28 | } |
29 | 29 | $content->addToProperty("class",(($index===0)?"visible":"hidden")." content"); |
@@ -19,8 +19,9 @@ |
||
19 | 19 | if (isset($type)) { |
20 | 20 | if ($type == "page") { |
21 | 21 | $this->asPageHeader($niveau); |
22 | - } else |
|
23 | - $this->asContentHeader($niveau); |
|
22 | + } else { |
|
23 | + $this->asContentHeader($niveau); |
|
24 | + } |
|
24 | 25 | } |
25 | 26 | $this->content=$content; |
26 | 27 | } |
@@ -17,14 +17,14 @@ discard block |
||
17 | 17 | * @version 1.001 |
18 | 18 | */ |
19 | 19 | class HtmlHeader extends HtmlSemDoubleElement { |
20 | - use TextAlignmentTrait,AttachedTrait; |
|
20 | + use TextAlignmentTrait, AttachedTrait; |
|
21 | 21 | protected $image; |
22 | 22 | |
23 | 23 | public function __construct($identifier, $niveau=1, $content=NULL, $type="page") { |
24 | 24 | parent::__construct($identifier, "div", "ui header"); |
25 | 25 | $this->_template='<%tagName% id="%identifier%" %properties%>%image%%wrapContentBefore%%content%%wrapContentAfter%</%tagName%>'; |
26 | 26 | if (isset($type)) { |
27 | - if ($type == "page") { |
|
27 | + if ($type=="page") { |
|
28 | 28 | $this->asPageHeader($niveau); |
29 | 29 | } else |
30 | 30 | $this->asContentHeader($niveau); |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | } |
34 | 34 | |
35 | 35 | public function asPageHeader($niveau) { |
36 | - $this->tagName="h" . $niveau; |
|
36 | + $this->tagName="h".$niveau; |
|
37 | 37 | } |
38 | 38 | |
39 | 39 | public function asContentHeader($niveau) { |
@@ -46,25 +46,25 @@ discard block |
||
46 | 46 | |
47 | 47 | public function asIcon($icon, $title, $subHeader=NULL) { |
48 | 48 | $this->addToProperty("class", "icon"); |
49 | - $this->image=new HtmlIcon("icon-" . $this->identifier, $icon); |
|
49 | + $this->image=new HtmlIcon("icon-".$this->identifier, $icon); |
|
50 | 50 | return $this->asTitle($title, $subHeader); |
51 | 51 | } |
52 | 52 | |
53 | 53 | public function asImage($src, $title, $subHeader=NULL) { |
54 | - $this->image=new HtmlImg("img-" . $this->identifier, $src, $title); |
|
54 | + $this->image=new HtmlImg("img-".$this->identifier, $src, $title); |
|
55 | 55 | return $this->asTitle($title, $subHeader); |
56 | 56 | } |
57 | 57 | |
58 | 58 | public function asTitle($title, $subHeader=NULL) { |
59 | 59 | if (!\is_object($title)) { |
60 | - $this->content=new HtmlDoubleElement("content-" . $this->identifier, "div"); |
|
60 | + $this->content=new HtmlDoubleElement("content-".$this->identifier, "div"); |
|
61 | 61 | $this->content->setContent($title); |
62 | 62 | } else { |
63 | 63 | $this->content=$title; |
64 | 64 | } |
65 | 65 | $this->content->setClass("content"); |
66 | 66 | if (isset($subHeader)) { |
67 | - $sub=new HtmlDoubleElement("subheader-" . $this->identifier, "div"); |
|
67 | + $sub=new HtmlDoubleElement("subheader-".$this->identifier, "div"); |
|
68 | 68 | $sub->setClass("sub header"); |
69 | 69 | $sub->setContent($subHeader); |
70 | 70 | $this->content->addContent($sub); |
@@ -4,11 +4,11 @@ |
||
4 | 4 | |
5 | 5 | |
6 | 6 | class HtmlAccordionMenuItem extends HtmlMenuItem { |
7 | - public function __construct($identifier,$title,$content) { |
|
8 | - parent::__construct($identifier, new HtmlAccordionItem("accordion-".$identifier, $title,$content)); |
|
7 | + public function __construct($identifier, $title, $content) { |
|
8 | + parent::__construct($identifier, new HtmlAccordionItem("accordion-".$identifier, $title, $content)); |
|
9 | 9 | } |
10 | 10 | |
11 | - public function setActive($value=true){ |
|
11 | + public function setActive($value=true) { |
|
12 | 12 | $this->content->setActive($value); |
13 | 13 | return $this; |
14 | 14 | } |
@@ -20,30 +20,30 @@ |
||
20 | 20 | $this->_title=$title; |
21 | 21 | } |
22 | 22 | |
23 | - public function setTitle($title){ |
|
23 | + public function setTitle($title) { |
|
24 | 24 | $this->_title=$title; |
25 | 25 | } |
26 | 26 | |
27 | - public function setIcon($icon){ |
|
27 | + public function setIcon($icon) { |
|
28 | 28 | $this->_icon=$icon; |
29 | 29 | } |
30 | 30 | |
31 | - protected function createTitleElement(){ |
|
32 | - $element=new HtmlSemDoubleElement("title-".$this->identifier,"div","title"); |
|
33 | - $element->setContent(array(new HtmlIcon("", $this->_icon),$this->_title)); |
|
34 | - if($this->_active===true) |
|
31 | + protected function createTitleElement() { |
|
32 | + $element=new HtmlSemDoubleElement("title-".$this->identifier, "div", "title"); |
|
33 | + $element->setContent(array(new HtmlIcon("", $this->_icon), $this->_title)); |
|
34 | + if ($this->_active===true) |
|
35 | 35 | $element->addToProperty("class", "active"); |
36 | 36 | return $element; |
37 | 37 | } |
38 | 38 | |
39 | - public function compile(JsUtils $js=NULL, &$view=NULL){ |
|
39 | + public function compile(JsUtils $js=NULL, &$view=NULL) { |
|
40 | 40 | $this->titleElement=$this->createTitleElement(); |
41 | - return parent::compile($js,$view); |
|
41 | + return parent::compile($js, $view); |
|
42 | 42 | } |
43 | 43 | |
44 | - public function setActive($value=true){ |
|
44 | + public function setActive($value=true) { |
|
45 | 45 | $this->_active=$value; |
46 | - if($value===true) |
|
46 | + if ($value===true) |
|
47 | 47 | $this->addToPropertyCtrl("class", "active", array("active")); |
48 | 48 | else |
49 | 49 | $this->removePropertyValue("class", "active"); |
@@ -31,8 +31,9 @@ discard block |
||
31 | 31 | protected function createTitleElement(){ |
32 | 32 | $element=new HtmlSemDoubleElement("title-".$this->identifier,"div","title"); |
33 | 33 | $element->setContent(array(new HtmlIcon("", $this->_icon),$this->_title)); |
34 | - if($this->_active===true) |
|
35 | - $element->addToProperty("class", "active"); |
|
34 | + if($this->_active===true) { |
|
35 | + $element->addToProperty("class", "active"); |
|
36 | + } |
|
36 | 37 | return $element; |
37 | 38 | } |
38 | 39 | |
@@ -43,10 +44,11 @@ discard block |
||
43 | 44 | |
44 | 45 | public function setActive($value=true){ |
45 | 46 | $this->_active=$value; |
46 | - if($value===true) |
|
47 | - $this->addToPropertyCtrl("class", "active", array("active")); |
|
48 | - else |
|
49 | - $this->removePropertyValue("class", "active"); |
|
47 | + if($value===true) { |
|
48 | + $this->addToPropertyCtrl("class", "active", array("active")); |
|
49 | + } else { |
|
50 | + $this->removePropertyValue("class", "active"); |
|
51 | + } |
|
50 | 52 | return $this; |
51 | 53 | } |
52 | 54 | } |
@@ -29,10 +29,11 @@ |
||
29 | 29 | if(isset($numCols)){ |
30 | 30 | $numCols=min(16,$numCols); |
31 | 31 | $numCols=max(1,$numCols); |
32 | - if($colSizing) |
|
33 | - $width=(int)(16/$numCols); |
|
34 | - else |
|
35 | - $this->_colSize=16/$numCols; |
|
32 | + if($colSizing) { |
|
33 | + $width=(int)(16/$numCols); |
|
34 | + } else { |
|
35 | + $this->_colSize=16/$numCols; |
|
36 | + } |
|
36 | 37 | for ($i=0;$i<$numCols;$i++){ |
37 | 38 | $this->addItem($width); |
38 | 39 | } |
@@ -16,24 +16,24 @@ discard block |
||
16 | 16 | * @author jc |
17 | 17 | * @version 1.001 |
18 | 18 | */ |
19 | -class HtmlGridRow extends HtmlSemCollection{ |
|
19 | +class HtmlGridRow extends HtmlSemCollection { |
|
20 | 20 | use TextAlignmentTrait; |
21 | 21 | |
22 | 22 | private $_colSize; |
23 | 23 | private $_implicite=false; |
24 | 24 | |
25 | - public function __construct( $identifier,$numCols=NULL,$colSizing=false,$implicite=false){ |
|
26 | - parent::__construct( $identifier,"div","row"); |
|
25 | + public function __construct($identifier, $numCols=NULL, $colSizing=false, $implicite=false) { |
|
26 | + parent::__construct($identifier, "div", "row"); |
|
27 | 27 | $this->_implicite=$implicite; |
28 | 28 | $width=null; |
29 | - if(isset($numCols)){ |
|
30 | - $numCols=min(16,$numCols); |
|
31 | - $numCols=max(1,$numCols); |
|
32 | - if($colSizing) |
|
29 | + if (isset($numCols)) { |
|
30 | + $numCols=min(16, $numCols); |
|
31 | + $numCols=max(1, $numCols); |
|
32 | + if ($colSizing) |
|
33 | 33 | $width=(int)(16/$numCols); |
34 | 34 | else |
35 | 35 | $this->_colSize=16/$numCols; |
36 | - for ($i=0;$i<$numCols;$i++){ |
|
36 | + for ($i=0; $i<$numCols; $i++) { |
|
37 | 37 | $this->addItem($width); |
38 | 38 | } |
39 | 39 | } |
@@ -44,12 +44,12 @@ discard block |
||
44 | 44 | * @param int $width |
45 | 45 | * @return \Ajax\semantic\html\content\HtmlGridRow |
46 | 46 | */ |
47 | - public function setWidth($width){ |
|
48 | - if(\is_int($width)){ |
|
47 | + public function setWidth($width) { |
|
48 | + if (\is_int($width)) { |
|
49 | 49 | $width=Wide::getConstants()["W".$width]; |
50 | 50 | } |
51 | 51 | $this->addToPropertyCtrl("class", $width, Wide::getConstants()); |
52 | - return $this->addToPropertyCtrl("class", "column",array("column")); |
|
52 | + return $this->addToPropertyCtrl("class", "column", array("column")); |
|
53 | 53 | } |
54 | 54 | |
55 | 55 | /** |
@@ -57,29 +57,29 @@ discard block |
||
57 | 57 | * @param int $index |
58 | 58 | * @return HtmlGridCol |
59 | 59 | */ |
60 | - public function getCol($index){ |
|
60 | + public function getCol($index) { |
|
61 | 61 | return $this->getItem($index); |
62 | 62 | } |
63 | 63 | |
64 | - public function setColsCount($colsCount,$toCreate=true){ |
|
64 | + public function setColsCount($colsCount, $toCreate=true) { |
|
65 | 65 | $this->setWidth($colsCount); |
66 | - if($toCreate===true){ |
|
66 | + if ($toCreate===true) { |
|
67 | 67 | $count=$this->count(); |
68 | - for($i=$count;$i<$colsCount;$i++){ |
|
68 | + for ($i=$count; $i<$colsCount; $i++) { |
|
69 | 69 | $this->addItem(null); |
70 | 70 | } |
71 | 71 | } |
72 | 72 | return $this; |
73 | 73 | } |
74 | 74 | |
75 | - public function addCols($colCount){ |
|
76 | - for($i=0;$i<$colCount;$i++){ |
|
75 | + public function addCols($colCount) { |
|
76 | + for ($i=0; $i<$colCount; $i++) { |
|
77 | 77 | $this->addItem(null); |
78 | 78 | } |
79 | 79 | return $this; |
80 | 80 | } |
81 | 81 | |
82 | - public function addCol($width=NULL){ |
|
82 | + public function addCol($width=NULL) { |
|
83 | 83 | return $this->addItem($width); |
84 | 84 | } |
85 | 85 | |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | * stretch the row contents to take up the entire column height |
88 | 88 | * @return \Ajax\semantic\html\content\HtmlGridRow |
89 | 89 | */ |
90 | - public function setStretched(){ |
|
90 | + public function setStretched() { |
|
91 | 91 | return $this->addToProperty("class", "stretched"); |
92 | 92 | } |
93 | 93 | |
@@ -95,20 +95,20 @@ discard block |
||
95 | 95 | * @param string $color |
96 | 96 | * @return \Ajax\semantic\html\content\HtmlGridRow |
97 | 97 | */ |
98 | - public function setColor($color){ |
|
99 | - return $this->addToPropertyCtrl("class", $color,Color::getConstants()); |
|
98 | + public function setColor($color) { |
|
99 | + return $this->addToPropertyCtrl("class", $color, Color::getConstants()); |
|
100 | 100 | } |
101 | 101 | |
102 | - public function setValues($values,$force=false){ |
|
102 | + public function setValues($values, $force=false) { |
|
103 | 103 | $count=$this->count(); |
104 | 104 | $valuesSize=\sizeof($values); |
105 | - if($force===true){ |
|
106 | - for($i=$count;$i<$valuesSize;$i++){ |
|
107 | - $this->addItem(new HtmlGridCol($this->identifier."-col-".($this->count()+1),null)); |
|
105 | + if ($force===true) { |
|
106 | + for ($i=$count; $i<$valuesSize; $i++) { |
|
107 | + $this->addItem(new HtmlGridCol($this->identifier."-col-".($this->count()+1), null)); |
|
108 | 108 | } |
109 | 109 | } |
110 | - $count=\min(array($this->count(),$valuesSize)); |
|
111 | - for($i=0;$i<$count;$i++){ |
|
110 | + $count=\min(array($this->count(), $valuesSize)); |
|
111 | + for ($i=0; $i<$count; $i++) { |
|
112 | 112 | $this->content[$i]->setValue($values[$i]); |
113 | 113 | } |
114 | 114 | return $this; |
@@ -118,15 +118,15 @@ discard block |
||
118 | 118 | * {@inheritDoc} |
119 | 119 | * @see \Ajax\common\html\HtmlCollection::createItem() |
120 | 120 | */ |
121 | - protected function createItem($value){ |
|
122 | - $col=new HtmlGridCol($this->identifier."-col-".($this->count()+1),$value); |
|
121 | + protected function createItem($value) { |
|
122 | + $col=new HtmlGridCol($this->identifier."-col-".($this->count()+1), $value); |
|
123 | 123 | return $col; |
124 | 124 | } |
125 | 125 | |
126 | - public function compile(JsUtils $js=NULL,&$view=NULL){ |
|
127 | - if($this->_implicite===true){ |
|
126 | + public function compile(JsUtils $js=NULL, &$view=NULL) { |
|
127 | + if ($this->_implicite===true) { |
|
128 | 128 | $this->_template="%wrapContentBefore%%content%%wrapContentAfter%"; |
129 | 129 | } |
130 | - return parent::compile($js,$view); |
|
130 | + return parent::compile($js, $view); |
|
131 | 131 | } |
132 | 132 | } |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | |
20 | 20 | public function __construct(JsUtils $js) { |
21 | 21 | parent::__construct($js); |
22 | - $this->tabs=array (); |
|
22 | + $this->tabs=array(); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | public function getTabs() { |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | } |
37 | 37 | |
38 | 38 | public function getTab($index) { |
39 | - if ($index>0&&$index<sizeof($this->tabs)) |
|
39 | + if ($index>0 && $index<sizeof($this->tabs)) |
|
40 | 40 | return $this->tabs [$index]; |
41 | 41 | } |
42 | 42 |
@@ -36,8 +36,9 @@ discard block |
||
36 | 36 | } |
37 | 37 | |
38 | 38 | public function getTab($index) { |
39 | - if ($index>0&&$index<sizeof($this->tabs)) |
|
40 | - return $this->tabs [$index]; |
|
39 | + if ($index>0&&$index<sizeof($this->tabs)) { |
|
40 | + return $this->tabs [$index]; |
|
41 | + } |
|
41 | 42 | } |
42 | 43 | |
43 | 44 | public function show($index) { |
@@ -53,8 +54,9 @@ discard block |
||
53 | 54 | */ |
54 | 55 | public function onShow($index, $jsCode) { |
55 | 56 | $tab=$this->getTab($index); |
56 | - if (isset($tab)) |
|
57 | - return $tab->onShow($jsCode); |
|
57 | + if (isset($tab)) { |
|
58 | + return $tab->onShow($jsCode); |
|
59 | + } |
|
58 | 60 | } |
59 | 61 | |
60 | 62 | /** |
@@ -65,8 +67,9 @@ discard block |
||
65 | 67 | */ |
66 | 68 | public function onShown($index, $jsCode) { |
67 | 69 | $tab=$this->getTab($index); |
68 | - if (isset($tab)) |
|
69 | - return $tab->onShown($jsCode); |
|
70 | + if (isset($tab)) { |
|
71 | + return $tab->onShown($jsCode); |
|
72 | + } |
|
70 | 73 | } |
71 | 74 | |
72 | 75 | /** |
@@ -77,8 +80,9 @@ discard block |
||
77 | 80 | */ |
78 | 81 | public function onHide($index, $jsCode) { |
79 | 82 | $tab=$this->getTab($index); |
80 | - if (isset($tab)) |
|
81 | - return $tab->onShow($jsCode); |
|
83 | + if (isset($tab)) { |
|
84 | + return $tab->onShow($jsCode); |
|
85 | + } |
|
82 | 86 | } |
83 | 87 | |
84 | 88 | /** |
@@ -89,7 +93,8 @@ discard block |
||
89 | 93 | */ |
90 | 94 | public function onHidden($index, $jsCode) { |
91 | 95 | $tab=$this->getTab($index); |
92 | - if (isset($tab)) |
|
93 | - return $tab->onShow($jsCode); |
|
96 | + if (isset($tab)) { |
|
97 | + return $tab->onShow($jsCode); |
|
98 | + } |
|
94 | 99 | } |
95 | 100 | } |
@@ -65,7 +65,7 @@ |
||
65 | 65 | } |
66 | 66 | |
67 | 67 | protected function compileEvents() { |
68 | - foreach ( $this->events as $event => $jsCode ) { |
|
68 | + foreach ($this->events as $event => $jsCode) { |
|
69 | 69 | $this->jquery_code_for_compile []="$( \"".$this->collapsed."\" ).on(\"".$event."\" , function (e) {".$jsCode."});"; |
70 | 70 | } |
71 | 71 | } |
@@ -9,7 +9,7 @@ |
||
9 | 9 | * @see \Ajax\common\SimpleComponent::compileEvents() |
10 | 10 | */ |
11 | 11 | protected function compileEvents() { |
12 | - foreach ( $this->events as $event => $jsCode ) { |
|
12 | + foreach ($this->events as $event => $jsCode) { |
|
13 | 13 | if ($event==="buttonClick") { |
14 | 14 | $this->jquery_code_for_compile []="$( \"#split-".preg_replace('/[^a-zA-Z0-9\-.]/s', '', $this->attachTo)."\" ).on(\"click\" , function( event, data ) {".$jsCode."});"; |
15 | 15 | } else { |