/Engine/Source/Runtime/Slate/Public/Framework/Application/SlateApplication.h
Unregisters the current game viewport from Slate. This method sends a final deactivation message to the viewport to allow it to do a final cleanup before being closed.
void UnregisterGameViewport()