MCPcopy Create free account
hub / github.com/defold/defold / NullCloseWindow

Function NullCloseWindow

engine/graphics/src/null/graphics_null.cpp:224–240  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

222 }
223
224 static void NullCloseWindow(HContext _context)
225 {
226 assert(_context);
227 NullContext* context = (NullContext*) _context;
228
229 if (dmPlatform::GetWindowStateParam(context->m_BaseContext.m_Window, WINDOW_STATE_OPENED))
230 {
231 PostDeleteTextures(context, true);
232 FrameBuffer& main = context->m_MainFrameBuffer;
233 delete [] (char*)main.m_ColorBuffer[0];
234 delete [] (char*)main.m_DepthBuffer;
235 delete [] (char*)main.m_StencilBuffer;
236 context->m_BaseContext.m_Width = 0;
237 context->m_BaseContext.m_Height = 0;
238 dmPlatform::CloseWindow(context->m_BaseContext.m_Window);
239 }
240 }
241
242 static void NullRunApplicationLoop(void* user_data, WindowStepMethod step_method, WindowIsRunning is_running)
243 {

Callers

nothing calls this directly

Calls 4

PostDeleteTexturesFunction · 0.70
assertFunction · 0.50
GetWindowStateParamFunction · 0.50
CloseWindowFunction · 0.50

Tested by

no test coverage detected