Skip to content

Commit

Permalink
Update FlxGame.hx
Browse files Browse the repository at this point in the history
  • Loading branch information
MAJigsaw77 authored Oct 1, 2024
1 parent 91acb98 commit a35f75d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions flixel/FlxGame.hx
Original file line number Diff line number Diff line change
Expand Up @@ -359,15 +359,13 @@ class FlxGame extends Sprite
#if (desktop && openfl <= "4.0.0")
stage.addEventListener(FocusEvent.FOCUS_OUT, onFocusLost);
stage.addEventListener(FocusEvent.FOCUS_IN, onFocus);
#else
#if sys
#elseif (sys && openfl >= "9.3.0")
stage.nativeWindow.addEventListener(Event.DEACTIVATE, onFocusLost);
stage.nativeWindow.addEventListener(Event.ACTIVATE, onFocus);
#else
stage.addEventListener(Event.DEACTIVATE, onFocusLost);
stage.addEventListener(Event.ACTIVATE, onFocus);
#end
#end

// Instantiate the initial state
resetGame();
Expand Down

0 comments on commit a35f75d

Please sign in to comment.