소스 검색

Merge pull request #1846 from CouleeApps/background-fix

Fix SDL/Mac report going into the background
Areloch 8 년 전
부모
커밋
de1f002adc
2개의 변경된 파일1개의 추가작업 그리고 5개의 파일을 삭제
  1. 0 4
      Engine/source/app/mainLoop.cpp
  2. 1 1
      Engine/source/windowManager/sdl/sdlWindow.cpp

+ 0 - 4
Engine/source/app/mainLoop.cpp

@@ -604,15 +604,11 @@ bool StandardMainLoop::doMainLoop()
             lastFocus = newFocus;
          }
          
-#ifndef TORQUE_OS_MAC         
          // under the web plugin do not sleep the process when the child window loses focus as this will cripple the browser perfomance
          if (!Platform::getWebDeployment())
             tm->setBackground(!newFocus);
          else
             tm->setBackground(false);
-#else
-         tm->setBackground(false);
-#endif
       }
       else
       {

+ 1 - 1
Engine/source/windowManager/sdl/sdlWindow.cpp

@@ -342,7 +342,7 @@ bool PlatformWindowSDL::isFocused()
    if( flags & SDL_WINDOW_INPUT_FOCUS || flags & SDL_WINDOW_INPUT_GRABBED || flags & SDL_WINDOW_MOUSE_FOCUS )
       return true;
 
-	return true;
+   return false;
 }
 
 bool PlatformWindowSDL::isMinimized()