Quantcast
WoWInterface - View Single Post - Mysterious taint for changing a drop down selection?
View Single Post
12-19-20, 12:03 PM   #5
LudiusMaximus
A Frostmaul Preserver
 
LudiusMaximus's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2018
Posts: 283
All right, I built my own drop down list, hoping that I can use this without spreading taint.

But it turns out that even this miminal example spreads the taint:

Lua Code:
  1. local myDropdown = CreateFrame("Frame", "myDropdown", UIParent, "UIDropDownMenuTemplate")
  2. myDropdown:SetPoint("TOP")
  3. UIDropDownMenu_SetWidth(myDropdown, 130)
  4.  
  5. local function MyDropdown_Initialize()
  6.  
  7.   local info = UIDropDownMenu_CreateInfo()
  8.  
  9.   info.text = "test"
  10.   info.value = 1
  11.   UIDropDownMenu_AddButton(info)
  12.  
  13.   info.value = 2
  14.   UIDropDownMenu_AddButton(info)
  15.  
  16.   info.value = 3
  17.   UIDropDownMenu_AddButton(info)
  18.  
  19.   info.value = 4
  20.   info.checked = true
  21.   UIDropDownMenu_AddButton(info)
  22.  
  23. end
  24.  
  25. UIDropDownMenu_Initialize(myDropdown, MyDropdown_Initialize)


You get the error like this:
  1. Go into combat.
  2. Open the game menu (click the button, do not press ESC which would exit combat).
  3. Click on "Interface".
  4. Chose the "Accessibilty" tab of the "Interface" window.
  5. Click my drop down menu at the top of the (UIParent) screen.
  6. Click the "Cancel" button in the bottom right of the "Interface" window.

Is this bugged or am I doing anything wrong?
__________________
~ Be the change you want to see in the world... of warcraft interface! ~
  Reply With Quote