1 | <?php |
||
17 | class HtmlDropdownItem extends HtmlDoubleElement { |
||
18 | protected $_htmlDropdown; |
||
19 | protected $class; |
||
20 | protected $itemClass; |
||
21 | protected $href; |
||
22 | protected $role; |
||
23 | protected $itemRole; |
||
24 | protected $target; |
||
25 | |||
26 | /** |
||
27 | * |
||
28 | * @param string $identifier the id |
||
29 | */ |
||
30 | public function __construct($identifier) { |
||
40 | |||
41 | public function setItemClass($itemClass) { |
||
45 | |||
46 | public function setItemRole($itemRole) { |
||
50 | |||
51 | /** |
||
52 | * Set the item class |
||
53 | * @param string $value |
||
54 | * @return $this default : '' |
||
55 | */ |
||
56 | public function setClass($value) { |
||
60 | |||
61 | /** |
||
62 | * Set the item caption |
||
63 | * @param string $value |
||
64 | * @return $this |
||
65 | */ |
||
66 | public function setCaption($value) { |
||
79 | |||
80 | public function disable() { |
||
84 | |||
85 | public function active() { |
||
89 | |||
90 | /** |
||
91 | * Set the item href |
||
92 | * @param string $value |
||
93 | * @return $this default : '#' |
||
94 | */ |
||
95 | public function setHref($value) { |
||
99 | |||
100 | /** |
||
101 | * Set the item role |
||
102 | * @param string $value |
||
103 | * @return $this default : '' |
||
104 | */ |
||
105 | public function setRole($value) { |
||
109 | |||
110 | public function isDivider() { |
||
113 | |||
114 | public function __toString() { |
||
117 | |||
118 | /** |
||
119 | * /* Initialise l'objet à partir d'un tableau associatif |
||
120 | * array("identifier"=>"id","caption"=>"","class"=>"","href"=>"","role"=>"") |
||
121 | * @see BaseHtml::addProperties() |
||
122 | */ |
||
123 | public function fromArray($array) { |
||
126 | |||
127 | public function run(JsUtils $js) { |
||
132 | |||
133 | /** |
||
134 | * Js component creation when dropdownItem is in Navs/Pills |
||
135 | * @param JsUtils $js |
||
136 | */ |
||
137 | public function runNav(JsUtils $js) { |
||
140 | |||
141 | public function getHref() { |
||
144 | |||
145 | public function addBadge($caption, $leftSeparator=" ") { |
||
151 | |||
152 | public function addGlyph($glyphicon, $left=true, $separator=" ") { |
||
162 | |||
163 | public function getTarget() { |
||
166 | |||
167 | public function setTarget($target) { |
||
171 | } |