|
@@ 47-55 (lines=9) @@
|
| 44 |
|
return $this->addToProperty("class", $this->_baseClass); |
| 45 |
|
} |
| 46 |
|
|
| 47 |
|
public function setVariations($variations) { |
| 48 |
|
$this->setProperty("class", $this->_baseClass); |
| 49 |
|
if (\is_string($variations)) |
| 50 |
|
$variations=\explode(" ", $variations); |
| 51 |
|
foreach ( $variations as $variation ) { |
| 52 |
|
$this->addVariation($variation); |
| 53 |
|
} |
| 54 |
|
return $this; |
| 55 |
|
} |
| 56 |
|
|
| 57 |
|
public function setState($state) { |
| 58 |
|
$this->setPropertyCtrl("class", $state, $this->_states); |
|
@@ 80-88 (lines=9) @@
|
| 77 |
|
return $this; |
| 78 |
|
} |
| 79 |
|
|
| 80 |
|
public function setStates($states) { |
| 81 |
|
$this->setProperty("class", $this->_baseClass); |
| 82 |
|
if (\is_string($states)) |
| 83 |
|
$states=\explode(" ", $states); |
| 84 |
|
foreach ( $states as $state ) { |
| 85 |
|
$this->addState($state); |
| 86 |
|
} |
| 87 |
|
return $this; |
| 88 |
|
} |
| 89 |
|
|
| 90 |
|
public function addIcon($icon, $before=true) { |
| 91 |
|
return $this->addContent(new HtmlIcon("icon-" . $this->identifier, $icon), $before); |