Thread Tools Display Modes
10-14-10, 06:00 AM   #1
BDelacroix
An Aku'mai Servant
AddOn Author - Click to view addons
Join Date: Jan 2006
Posts: 33
Defiant and Large NormaTexture

I am seeking help on this after working with it for the last few weeks in beta and now with 4.01 on us, it is more imperative that I find the answer.

As always, I am sure it will be soemthing simple to everyone else that I am just somehow overlooking.

Here is the gist of the problem (there are two but I'll cover them in seperate threads). Until 4.0 this thing worked great.

Now, with 4.0 my normal texture for the button is huge. No coaxing at all will change it. It remains huge (64 x 64 I believe). What is odd is it is only the normal texture that remains obstinately and defiantly huge. I've tried explicitly setting the size even down to 0 x 0 and it ignores me completely.

The below code has no size setting functions in it. It didn't seem to matter anymore anyway. Everything except the normaltexture size is correct. Even the cooldown layer is the correct size. It makes no sense to me why that is.

If I remove the ActionButtonTemplate from the inheritance, the texture size is correct but I lose all the functionality of the button for changing textures when pressed or disabled and the cooldown frame.

Code:
			trap_b[t] = CreateFrame("Button","trapper_button"..t,trapper,"ActionButtonTemplate, SecureActionButtonTemplate")
			trap_b[t].cooldown = CreateFrame("Cooldown","trapper_button"..t.."Cooldown",trap_b[t],"CooldownFrameTemplate")

		
		
-- Set type and spell for each state
		trap_b[t]:SetAttribute("type","spell")
		trap_b[t]:SetAttribute("spell",trap_n[t])

-- Set the image for the button
		trap_b[t]:SetNormalTexture(trap_i[t])
		trap_b[t]:SetPushedTexture(trap_i[t])

		trap_b[t]:SetPoint("CENTER",trapper,offx[t],offy[t])
		trap_b[t]:RegisterEvent("SPELL_UPDATE_COOLDOWN")
		trap_b[t]:SetScript("OnEvent",trapper_buttonevent)
		trap_b[t]:SetScript("OnEnter",trapper_tooltipon)
		trap_b[t]:SetScript("OnLeave",trapper_tooltipoff)
		
		trap_b[t].tipID=trap_sid[t]

		trap_b[t]:Show()
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Defiant and Large NormaTexture


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off