Thread: Bag Lua Problem
View Single Post
07-04-10, 06:46 PM   #8
Vrul
A Scalebane Royal Guard
 
Vrul's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2007
Posts: 404
You may want to reconsider how you are hiding the container components too. No need to keep hiding them over and over when you could just do it once. Also, there is more than one BackgroundMiddle texture to hide.

Code:
------------
--Hide Bag Backgrounds
------------

local function Hide(frame)
	frame:Hide()
	frame.Show = frame.Hide
end

for i = 1, NUM_CONTAINER_FRAMES do
	Hide(_G["ContainerFrame"..i.."CloseButton"])
	Hide(_G["ContainerFrame"..i.."BackgroundTop"])
	Hide(_G["ContainerFrame"..i.."BackgroundBottom"])
	for bg = 1, MAX_BG_TEXTURES do
		Hide(_G["ContainerFrame"..i.."BackgroundMiddle"..bg])
	end
end
  Reply With Quote