MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / Show

Method Show

Source/Engine/Platform/Base/WindowBase.cpp:541–566  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

539}
540
541void WindowBase::Show()
542{
543 const auto clientSize = GetClientSize();
544 const auto width = static_cast<int32>(clientSize.X);
545 const auto height = static_cast<int32>(clientSize.Y);
546 _visible = true;
547
548 // Ensure to have backbuffer and swapchain ready
549 if (InitSwapChain())
550 {
551 Platform::Fatal(TEXT("Cannot init rendering output for a window."));
552 }
553
554 if (RenderTask)
555 {
556 // Resize render task to fit WindowBase client size
557 RenderTask->Resize(width, height);
558
559 // Enable rendering
560 RenderTask->Enabled = true;
561 }
562
563 // Call GUI event
564 OnResize(width, height);
565 OnShow();
566}
567
568void WindowBase::Hide()
569{

Callers

nothing calls this directly

Calls 2

GetClientSizeFunction · 0.85
ResizeMethod · 0.45

Tested by

no test coverage detected