Wowpedia
Advertisement
Wowpedia
240,483
pages

Returns whether the object belongs to a given widget type.

isType = UIObject:IsObjectType(type)

Argument

type 
string - Name of the widget type.

Return

isType 
boolean - Returns true if the widget object is of that type, or any of its parent classes.

Example

local f = CreateFrame("Frame")
print(f:IsObjectType("Region")) -- true, Frame is also a Region
print(f:IsObjectType("Frame"))  -- true
print(f:IsObjectType("Button")) -- false, Frame is not a Button

Patch changes

  • WoW Icon update.png Patch 1.11.0 / API (2006-06-19): Changed to Region:IsObjectType("type")[1]
  • WoW Icon update.png Patch 1.10.0 / API (2006-03-28): Added as Frame:IsObjectType("type"), Texture:IsObjectType("type") and FontString:IsObjectType("type")[2]
    Previously was Frame:IsFrameType("type"), which remained an alias for a time

See also

External links

References

  1. ^ Blizzard Entertainment slouken 2006-05-12. Re: Upcoming 1.11 Changes - Concise List. Archived from the original on 2006-05-12.
  2. ^ Blizzard Entertainment slouken 2006-01-19. Re: Upcoming 1.10 Changes - Concise List. Archived from the original on 2006-01-19.
Advertisement