Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
WoW
Talk
English
Views
Read
Edit
History
More
Search
Navigation
Home
Random page
Help using wiki
Editions
for WoW
for WildStar
for Solar2D
Documentation
for WoW
for WildStar
Reference
WoW
⦁ FrameXML
⦁ AddOns
⦁ API
⦁ WoW Lua
WildStar
⦁ AddOns
⦁ API
⦁ WildStar Lua
Engine
Tools
What links here
Related changes
Special pages
Page information
Site
Recent Changes
Editing
WoW:USEROBJECT MenuClass
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Methods == ;:Activate() : Creates the menu frame if it has not already been set with :SetMenuFrame(). ;:AddItem(<string> text, <function> func, <number> isTitle) : Add a menu item with ''text'' text that does ''func''. Requires at least 1. ;:GetAttribute(<string|number> text, <string|number> attribute) : Gets an attribute for the given menu item. ;:New() : Allocate memory for the new menu and set the defaults. Required. Returns the menu. ;:RemoveItem(<string> text) : Remove the first menu item that matches ''text'' ;:SetAnchor(<string> anchor) : Set the ''anchor''. Optional. Default: "cursor" ;:SetAttribute(<string|number> text, <string|number> attribute, <string|number> value) : Sets an attribute for the given menu item. ;:SetDisplayMode(<string> displayMode) : Set the ''displayMode''. Optional. Default: "MENU" ;:SetAutoHideDelay(<number> autoHideDelay) : Set the ''autoHideDelay''. Optional. Default: nil (does not auto close) ;:SetMenuFrame(<menuFrame> menuFrame) : Set the ''menuFrame''. Optional. Default: self generating menuFrame. If set, this must be a frame that inherits '''UIDropDownMenuTemplate'''. ;:SetX(<number> x[, <boolean> save]) : Set the ''x'' offset. Optional. Default: nil (0 if ''anchor'' is not "cursor"). If save resolves to true, ''x'' will be added to rather than replaced. ;:SetY(<number> y[, <boolean> save]) : Set the ''y'' offset. Optional. Default: nil (0 if ''anchor'' is not "cursor"). If save resolves to true, ''y'' will be added to rather than replaced. ;:Show() : Show the menu.
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)