TheUdderOne57699@legacy41576782 (talk | contribs) No edit summary |
Charibot@legacy41530750 (talk | contribs) m (catfix, Replaced: {{framexml → <br>{{framexml) |
||
(4 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
+ | <br>{{framexmlfunc|FrameXML/ContainerFrame.lua}} __NOTOC__ |
||
− | <center>'''ToggleBag''' ''-Documentation by AlexanderYoshi-''</center> |
||
⚫ | |||
ToggleBag(bagNum); |
ToggleBag(bagNum); |
||
⚫ | |||
− | ---- |
||
⚫ | |||
− | :(Number bagNum) |
||
+ | == Parameters == |
||
⚫ | |||
⚫ | |||
⚫ | |||
− | ---- |
||
+ | |||
− | + | === Returns === |
|
:;nil |
:;nil |
||
⚫ | |||
− | ---- |
||
+ | |||
⚫ | |||
ToggleBag(2); |
ToggleBag(2); |
||
− | ;''Result'' |
||
− | |||
− | ---- |
||
− | ;''Description'' |
||
− | |||
− | : Opens or closes the specified bag. |
||
− | |||
− | |||
− | : NOTE: |
||
− | : When toggling with the keyboard, this function doesnt appear to be called. |
||
− | : When closing the bag using the "x" mark, this function is called. |
||
− | |||
− | |||
− | : Tested using the following code: |
||
− | |||
− | local pre_ToggleBag |
||
− | function testToggle_OnLoad() |
||
− | pre_ToggleBag = ToggleBag; |
||
− | ToggleBag = testToggle_ShowToggle(); |
||
− | end |
||
− | function testToggle_ShowToggle() |
||
− | DEFAULT_CHAT_FRAME:AddMessage("Bag Toggled!"); |
||
− | end |
||
+ | == Details == |
||
− | ---- |
||
+ | : If toggling the backpack with the keyboard, this function is called when opening but NOT when closing. Closing appears to be done by ToggleBackpack(). However, if the mouse is used to close the Backpack then this function does respond. |
||
− | {{Template:WoW API}} |
||
− | [[Category:API Functions|ToggleBag]] |
||
− | [[Category:API Container Functions|ToggleBag]] |
||
− | [[Category:API Toggle Functions|ToggleBag]] |
Revision as of 00:41, 15 July 2008
- This function is implemented in
FrameXML/ContainerFrame.lua
.
- This function is implemented in
ToggleBag(bagNum);
Opens or closes the specified bag.
Parameters
Arguments
- bagNum
- Number - the bagId you want to toggle open or close
Returns
- nil
Example
ToggleBag(2);
Details
- If toggling the backpack with the keyboard, this function is called when opening but NOT when closing. Closing appears to be done by ToggleBackpack(). However, if the mouse is used to close the Backpack then this function does respond.