View Single Post
02-11-12, 11:11 PM   #6
yj589794
A Rage Talon Dragon Guard
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 314
The spawning of the headers should be fairly generic as long as you make sure the config values are defined for your layout:
Code:
local toStr = tostring

local function spawnFunction(self)
	self:SetActiveStyle('oUF_EPRaid')

	-- define the raid groups
	local raid = {}
	for group = 1, NUM_RAID_GROUPS do
		local header = self:SpawnHeader(nil, nil, 'party,raid',
						'showPlayer', true,
						'showParty', true,
						'showRaid', true,
						'groupFilter', toStr(group),
						'yOffset', -config.SPACING,
						'oUF-initialConfigFunction', ([[
							local unit = ...
							self:SetWidth(%d)
							self:SetHeight(%d)
						]]):format(config.RAIDUNITWIDTH, config.UNITHEIGHT)
		)

		if group > 1 then
			header:SetPoint('TOPLEFT', raid[group - 1], 'TOPRIGHT', config.SPACING, 0)
		else
			header:SetPoint('TOPLEFT', UIParent, 'BOTTOMLEFT', 15, 350)
		end
		raid[group] = header
	end
end
  Reply With Quote