WoWInterface SVN phUnitFrames

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /trunk
    from Rev 3 to Rev 2
    Reverse comparison

Rev 3 → Rev 2

phUnitFrame.lua
60,7 → 60,6
end;
end);
 
frame.auras = {};
frame.buffs = phUnitFrame.createAuraButtons(frame,model.buffs);
frame.debuffs = phUnitFrame.createAuraButtons(frame,model.debuffs);
 
394,24 → 393,26
end,
 
updateAuras = function(frame,buttons,bconfig)
local list = frame.auras;
local auraCount = 0;
local list = {};
for i=1,100 do
local name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellId = UnitAura(frame.unit,i,bconfig.filter);
if name == nil then
break;
break;
end;
if not list[i] then
list[i] = {};
end;
list[i].index = i;
list[i].type = debuffType;
list[i].icon = icon;
list[i].count = count;
list[i].duration = duration;
list[i].expirationTime = expirationTime;
list[i].spellId = spellId;
auraCount = i;
local aura = {
index = i,
type = debuffType,
icon = icon,
count = count,
duration = duration,
expirationTime = expirationTime,
};
--print(name,spellId);
if not list[spellId] then
list[spellId] = aura;
else
list[spellId].count = list[spellId].count + 1;
end
end;
 
for i=1,table.getn(buttons) do
426,16 → 427,15
break;
end;
local found;
for j=1,auraCount do
local aura = list[j];
for spellId,aura in pairs(list) do
if aura.type == button.type or (aura.type == nil and button.type == "None") then
found = j;
found = spellId;
break;
end;
end;
if found then
phUnitFrame.updateAura(button,bconfig.filter,list[found]);
list[found].count = -1;
list[found] = nil;
end;
end
 
448,23 → 448,16
order = bconfig.combat;
end;
 
for i=1,table.getn(order) do
local spellId = order[i];
for j=1,auraCount do
local aura = list[j];
if aura.count >= 0 then
if aura.spellId == spellId then
phUnitFrame.updateAura(buttons[b],bconfig.filter,aura);
b = b + 1;
if not buttons[b] then
return;
end;
break;
end;
end;
end;
for j=1,table.getn(order) do
local spellId = order[j];
if list[spellId] then
phUnitFrame.updateAura(buttons[b],bconfig.filter,list[spellId]);
b = b + 1;
if not buttons[b] then
return;
end;
end;
end;
 
--[[
local j = 1;
for i=1,table.getn(buttons) do
phUnitFrames.lua
238,7 → 238,6
end;
end;
end;
 
 
for i,child in pairs(childs) do
child:update();