This member cannot be used in scripts, but is usable in the command bar and plugins.
For thread safety, this property is not safe to read in an unsynchronized thread.
WindowFocused fires immediately when the user starts interacting with the PluginGui’s window, usually by clicking on it. This functions works similarly to the similarly-named
UserInputService/WindowFocused event. It fires before any
GuiObject/InputBegan events related to mouse buttons.
PluginGui is in focus and the user focuses this PluginGui, then this event fires after the other’s
PluginGui/WindowFocusReleased|WindowFocusReleased event. However, if the main game window was in focus, this event fires after
Detecting PluginGui Focus State
This code sample demonstrates how the focus state of a
PluginGui can be tracked using the
PluginGui/WindowFocusReleased|WindowFocusReleased events. It changes the
PluginGui/Title|Title as the focus state changes.