1 | <?php |
||
38 | class ThemeManager extends \hiqdev\yii2\collection\Manager implements \yii\base\BootstrapInterface |
||
39 | { |
||
40 | /** |
||
41 | * @var array basic pathMap for all themes, will be merged with theme own pathMap |
||
42 | */ |
||
43 | public $pathMap = []; |
||
44 | |||
45 | /** |
||
46 | * {@inheritdoc} |
||
47 | */ |
||
48 | protected $_itemClass = Theme::class; |
||
49 | |||
50 | /** |
||
51 | * @var string default theme name |
||
52 | */ |
||
53 | protected $_defaultTheme; |
||
54 | |||
55 | /** |
||
56 | * Sets the default theme name. |
||
57 | * |
||
58 | * @param string $theme default theme name |
||
59 | */ |
||
60 | public function setDefaultTheme($theme) |
||
64 | |||
65 | /** |
||
66 | * Returns the default theme. Returns the first of available themes by default. |
||
67 | * |
||
68 | * @return string default theme name |
||
69 | */ |
||
70 | public function getDefaultTheme() |
||
79 | |||
80 | protected $_view; |
||
81 | |||
82 | /** |
||
83 | * @return \yii\web\View |
||
84 | * @see setView |
||
85 | */ |
||
86 | public function getView() |
||
94 | |||
95 | /** |
||
96 | * You can change the View for theme manager. |
||
97 | * @param \yii\web\View $view the view object that will be used to render views or view files |
||
98 | */ |
||
99 | public function setView($view) |
||
103 | |||
104 | /** |
||
105 | * @var Theme current theme object |
||
106 | */ |
||
107 | protected $_theme; |
||
108 | |||
109 | /** |
||
110 | * Changes theme. |
||
111 | * @param string theme name |
||
112 | * @throws InvalidConfigException |
||
113 | */ |
||
114 | public function setTheme($name) |
||
121 | |||
122 | public function getTheme() |
||
134 | |||
135 | public function getSettings() |
||
139 | |||
140 | /** |
||
141 | * @return bool |
||
142 | */ |
||
143 | public static function isHomePage() |
||
161 | |||
162 | /** |
||
163 | * @var AssetBundle[] assets to be registered at bootstrap |
||
164 | */ |
||
165 | public $assets = []; |
||
166 | |||
167 | /** |
||
168 | * Register all the assets. |
||
169 | */ |
||
170 | public function registerAssets() |
||
177 | |||
178 | /** |
||
179 | * @var bool is already bootstrapped |
||
180 | */ |
||
181 | protected $_isBootstrapped = false; |
||
182 | |||
183 | /** |
||
184 | * {@inheritdoc} |
||
185 | */ |
||
186 | public function bootstrap($app) |
||
203 | |||
204 | /** |
||
205 | * @return SettingsStorageInterface |
||
206 | */ |
||
207 | public function getSettingsStorage() |
||
211 | |||
212 | /** |
||
213 | * @return array |
||
214 | */ |
||
215 | public function getThemeSettings() |
||
219 | } |
||
220 |
This method has been deprecated. The supplier of the class has supplied an explanatory message.
The explanatory message should give you some clue as to whether and when the method will be removed from the class and what other method or class to use instead.