Showing the changes to interface/src/Application.cpp (1 of 9 files). Show all
Unified · Split
| @@ -2155,6 +2155,19 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 2154 unmodified lines | |||
| 2155 | return QSizeF(0.0f, 0.0f); | 2155 | return QSizeF(0.0f, 0.0f); |
| 2156 | }); | 2156 | }); |
| 2157 | 2157 | ||
| 2158 | Texture::setUnboundTextureForUUIDOperator([this](const QUuid& entityID) -> gpu::TexturePointer { | ||
| 2159 | if (_aboutToQuit) { | ||
| 2160 | return nullptr; | ||
| 2161 | } | ||
| 2162 | |||
| 2163 | auto renderable = getEntities()->renderableForEntityId(entityID); | ||
| 2164 | if (renderable) { | ||
| 2165 | return renderable->getTexture(); | ||
| 2166 | } | ||
| 2167 | |||
| 2168 | return nullptr; | ||
| 2169 | }); | ||
| 2170 | |||
| 2158 | connect(this, &Application::aboutToQuit, [this]() { | 2171 | connect(this, &Application::aboutToQuit, [this]() { |
| 2159 | setKeyboardFocusEntity(UNKNOWN_ENTITY_ID); | 2172 | setKeyboardFocusEntity(UNKNOWN_ENTITY_ID); |
| 2160 | }); | 2173 | }); |