Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions flixel/FlxState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -202,13 +202,17 @@ class FlxState extends FlxContainer
* This method is called after the game loses focus.
* Can be useful for third party libraries, such as tweening engines.
*/
public function onFocusLost():Void {}
public function onFocusLost():Void {
if (subState != null) subState.onFocusLost();
}

/**
* This method is called after the game receives focus.
* Can be useful for third party libraries, such as tweening engines.
*/
public function onFocus():Void {}
public function onFocus():Void {
if (subState != null) subState.onFocus();
}

/**
* This function is called whenever the window size has been changed.
Expand Down