adding new "saver" setting
[drnoksnes] / platform / sdlvscalers.cpp
index 8f7b39e..cd48c33 100644 (file)
@@ -626,15 +626,15 @@ public:
 
        bool filter(const SDL_Event& event)
        {
-               if (event.type == SDL_ACTIVEEVENT) {
-                       if (scaler && (event.active.state & SDL_APPINPUTFOCUS)) {
-                               if (event.active.gain)
-                                       scaler->resume();
-                               else
-                                       scaler->pause();
-
-                               return true;
+               if (event.type == SDL_ACTIVEEVENT &&
+                 (event.active.state & SDL_APPINPUTFOCUS)) {
+                       if (event.active.gain) {
+                               resume();
+                       } else {
+                               pause();
                        }
+
+                       return true;
                }
 
                return false;