Listening to the application's focus changing

In release v39 we have added a new helper function: BindToApplicationActivationStateChanged. This exposes some functionality previously only available in C++: FSlateApplication::Get().OnApplicationActivationStateChanged().

You can use this to listen to when the application's "activation state" changes, i.e. whether the game window is in focus or not. This can enable you to handle people e.g. Alt+Tabbing in & out of your application.

There is an equivalent UnbindFromApplicationActivationStateChanged you can use to unbind the listener you added if desired.

Last updated

Was this helpful?