We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c9e1865 commit 773f862Copy full SHA for 773f862
engine/system/win/sys_main.cpp
@@ -842,14 +842,16 @@ bool sys_main_c::Run(int argc, char** argv)
842
843
// Run frame loop
844
while (exitFlag == false) {
845
- glfwPollEvents();
+ if (minimized)
846
+ glfwWaitEventsTimeout(); // while minimized, puts process to sleep until it receives an event
847
+ else
848
+ glfwPollEvents();
849
auto wnd = (GLFWwindow*)video->GetWindowHandle();
850
if (glfwWindowShouldClose(wnd)) {
851
Exit();
852
break;
853
}
- if (minimized == false)
- core->Frame();
854
+ core->Frame();
855
856
if (threadError) {
857
Error(threadError);
0 commit comments