Only request attention if window has no focus.

This commit is contained in:
Bartosz Taudul 2022-10-13 20:44:31 +02:00
parent b66c3a0e30
commit d0968844d8
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3

View File

@ -153,7 +153,10 @@ void Backend::Run()
void Backend::Attention()
{
glfwRequestWindowAttention( s_window );
if( !glfwGetWindowAttrib( s_window, GLFW_FOCUSED ) )
{
glfwRequestWindowAttention( s_window );
}
}
void Backend::NewFrame( int& w, int& h )