1 | <?php |
||
11 | trait SelectableTrait |
||
12 | { |
||
13 | /** |
||
14 | * @var string |
||
15 | */ |
||
16 | private $text = ''; |
||
17 | |||
18 | /** |
||
19 | * @var bool |
||
20 | */ |
||
21 | private $showItemExtra = false; |
||
22 | |||
23 | /** |
||
24 | * @var bool |
||
25 | */ |
||
26 | private $disabled = false; |
||
27 | |||
28 | /** |
||
29 | * @var int |
||
30 | */ |
||
31 | private $numberOfRows = 0; |
||
32 | |||
33 | /** |
||
34 | * @var int |
||
35 | */ |
||
36 | private $startRowNumber = 0; |
||
37 | |||
38 | /** |
||
39 | * Returns the number of terminal rows the item takes |
||
40 | */ |
||
41 | public function getNumberOfRows() : int |
||
45 | |||
46 | /** |
||
47 | * Sets the row number the item starts at in the frame |
||
48 | */ |
||
49 | public function setStartRowNumber(int $rowNumber) : void |
||
53 | |||
54 | /** |
||
55 | * Returns the row number the item starts at in the frame |
||
56 | */ |
||
57 | public function getStartRowNumber() : int |
||
61 | |||
62 | /** |
||
63 | * The output text for the item |
||
64 | */ |
||
65 | public function getRows(MenuStyle $style, bool $selected = false) : array |
||
96 | |||
97 | /** |
||
98 | * Can the item be selected |
||
99 | */ |
||
100 | public function canSelect() : bool |
||
104 | |||
105 | public function showsItemExtra() : bool |
||
109 | |||
110 | /** |
||
111 | * Enable showing item extra |
||
112 | */ |
||
113 | public function showItemExtra() : void |
||
117 | |||
118 | /** |
||
119 | * Disable showing item extra |
||
120 | */ |
||
121 | public function hideItemExtra() : void |
||
125 | } |
||
126 |