mirror of
https://github.com/wolfpld/tracy.git
synced 2026-10-23 09:10:51 +00:00
Don't throttle the first Wayland frame on unknown focus state.
This commit is contained in:
@@ -1143,9 +1143,11 @@ void Backend::Run()
|
||||
#endif
|
||||
|
||||
timespec zero = {};
|
||||
bool first = true;
|
||||
while( s_running && wl_display_dispatch_timeout( s_dpy, &zero ) != -1 )
|
||||
{
|
||||
if( tracy::s_config.focusLostLimit && !s_hasFocus ) std::this_thread::sleep_for( std::chrono::milliseconds( 50 ) );
|
||||
if( !first && tracy::s_config.focusLostLimit && !s_hasFocus ) std::this_thread::sleep_for( std::chrono::milliseconds( 50 ) );
|
||||
first = false;
|
||||
s_redraw();
|
||||
s_mainThreadTasks->Run();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user