wowpedia
Main Menu


Returns true if the widget object belongs to a given widget type or its subtypes.

isType = FrameScriptObject:IsObjectType(objectType)

Arguments

objectType
string

Returns

isType
boolean

Details

Example

local f = CreateFrame("Button")

print(f:IsObjectType("Button")) -- true
print(f:IsObjectType("Frame"))  -- true, Button is also a Frame
print(f:IsObjectType("Region")) -- true, Button is also a Region
print(f:IsObjectType("Object")) -- true, Button is also an Object

print(f:IsObjectType("CheckButton")) -- false, Button is a superclass / parent type of CheckButton