создает виджет
| 161 | |
| 162 | // создает виджет |
| 163 | Widget* PointerManager::baseCreateWidget( |
| 164 | WidgetStyle _style, |
| 165 | std::string_view _type, |
| 166 | std::string_view _skin, |
| 167 | const IntCoord& _coord, |
| 168 | Align _align, |
| 169 | std::string_view _layer, |
| 170 | std::string_view _name) |
| 171 | { |
| 172 | Widget* widget = |
| 173 | WidgetManager::getInstance() |
| 174 | .createWidget(_style, _type, _skin, _coord, /*_align, */ nullptr, nullptr, /*this, */ _name); |
| 175 | mWidgetChild.push_back(widget); |
| 176 | |
| 177 | widget->setAlign(_align); |
| 178 | |
| 179 | // присоединяем виджет с уровню |
| 180 | if (!_layer.empty()) |
| 181 | LayerManager::getInstance().attachToLayerNode(_layer, widget); |
| 182 | return widget; |
| 183 | } |
| 184 | |
| 185 | // удаляет всех детей |
| 186 | void PointerManager::_destroyAllChildWidget() |
nothing calls this directly
no test coverage detected