| 98 | } |
| 99 | |
| 100 | void ComponentContainer::removeAll() |
| 101 | { |
| 102 | if (!_componentMap.empty()) |
| 103 | { |
| 104 | for (auto&& iter : _componentMap) |
| 105 | { |
| 106 | iter.second->onRemove(); |
| 107 | iter.second->setOwner(nullptr); |
| 108 | iter.second->release(); |
| 109 | } |
| 110 | |
| 111 | _componentMap.clear(); |
| 112 | _owner->unscheduleUpdate(); |
| 113 | } |
| 114 | } |
| 115 | |
| 116 | void ComponentContainer::visit(float delta) |
| 117 | { |
no test coverage detected