WoW API < GetMouseFocus

Returns the frame that is currently receiving mouse events. The frame must have enableMouse="true"

frameID = GetMouseFocus();

Parameters Edit

Arguments Edit


Results Edit

Table - The frame that currently has the mouse focus. *NOTE: This can momentarily return nil if GetMouseFocus() is called when selecting "Inspect" on another player. This is likely an API bug in 4.1+.

Example Edit

You can get the name of the mouse-enabled frame beneath the pointer with this:

message( "The mouse is over " .. GetMouseFocus():GetName() );

Result Edit

The mouse is over WorldFrame

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.