| 6 | LayerStack::~LayerStack() {} |
| 7 | |
| 8 | void LayerStack::PushLayer(const Ref<Layer>& layer) { |
| 9 | if (m_layers.empty()) { |
| 10 | m_layers.push_back(layer); |
| 11 | current_it = std::begin(m_layers); |
| 12 | } else { |
| 13 | current_it = m_layers.emplace(current_it, layer); |
| 14 | } |
| 15 | } |
| 16 | |
| 17 | void LayerStack::PushLayer(Ref<Layer>&& layer) { |
| 18 | if (m_layers.empty()) { |