Remove some locals
This commit is contained in:
@ -312,7 +312,6 @@ end
|
|||||||
|
|
||||||
function MyEquipment:OnEnable()
|
function MyEquipment:OnEnable()
|
||||||
MyEquipmentFramePortrait:SetTexture("Interface\\Addons\\MyBags\\Skin\\MyEquipmentPortrait")
|
MyEquipmentFramePortrait:SetTexture("Interface\\Addons\\MyBags\\Skin\\MyEquipmentPortrait")
|
||||||
local key, value
|
|
||||||
for key,value in pairs( SLOTNAMES ) do -- Just in case Blizzard shuffles the slot name table around
|
for key,value in pairs( SLOTNAMES ) do -- Just in case Blizzard shuffles the slot name table around
|
||||||
local slotId = GetInventorySlotInfo(value)
|
local slotId = GetInventorySlotInfo(value)
|
||||||
MYEQUIPMENT_SLOT[slotId] = value
|
MYEQUIPMENT_SLOT[slotId] = value
|
||||||
@ -355,7 +354,6 @@ function MyEquipment:UserDropDown_Initialize()
|
|||||||
local frame = this:GetParent():GetParent()
|
local frame = this:GetParent():GetParent()
|
||||||
local selectedValue = UIDropDownMenu_GetSelectedValue(this)
|
local selectedValue = UIDropDownMenu_GetSelectedValue(this)
|
||||||
|
|
||||||
local i
|
|
||||||
for i = 1, charnum do
|
for i = 1, charnum do
|
||||||
local info = {
|
local info = {
|
||||||
["text"] = chars[i],
|
["text"] = chars[i],
|
||||||
@ -523,7 +521,7 @@ end
|
|||||||
|
|
||||||
function MyEquipment:LayoutEquipmentFrame(self)
|
function MyEquipment:LayoutEquipmentFrame(self)
|
||||||
local itemBase = "MyEquipmentSlotsItem"
|
local itemBase = "MyEquipmentSlotsItem"
|
||||||
local texture, count, locked, quality, ammo, key, value, id
|
local texture, count, locked, quality, id
|
||||||
local slotColor = ((self.GetOpt("SlotColor")) or MYBAGS_SLOTCOLOR)
|
local slotColor = ((self.GetOpt("SlotColor")) or MYBAGS_SLOTCOLOR)
|
||||||
local charID = self:GetCurrentPlayer()
|
local charID = self:GetCurrentPlayer()
|
||||||
local hasRelic = self:GetRelic(charID)
|
local hasRelic = self:GetRelic(charID)
|
||||||
@ -532,13 +530,15 @@ function MyEquipment:LayoutEquipmentFrame(self)
|
|||||||
if self.aioiOrder and (hasRelic or hideAmmo) then
|
if self.aioiOrder and (hasRelic or hideAmmo) then
|
||||||
self.curCol = self.curCol + 1
|
self.curCol = self.curCol + 1
|
||||||
end
|
end
|
||||||
for key,value in pairs( SLOTNAMES ) do
|
|
||||||
|
for key, value in pairs( SLOTNAMES ) do
|
||||||
local slot = GetInventorySlotInfo(value)
|
local slot = GetInventorySlotInfo(value)
|
||||||
local itemButton = _G[itemBase .. slot]
|
local itemButton = _G[itemBase .. slot]
|
||||||
if self.curCol >= self.GetOpt("Columns") then
|
if self.curCol >= self.GetOpt("Columns") then
|
||||||
self.curCol = 0
|
self.curCol = 0
|
||||||
self.curRow = self.curRow + 1
|
self.curRow = self.curRow + 1
|
||||||
end
|
end
|
||||||
|
|
||||||
itemButton:Show()
|
itemButton:Show()
|
||||||
itemButton:ClearAllPoints()
|
itemButton:ClearAllPoints()
|
||||||
itemButton:SetPoint("TOPLEFT", self.frame:GetName(), "TOPLEFT", self:GetXY(self.curRow, self.curCol))
|
itemButton:SetPoint("TOPLEFT", self.frame:GetName(), "TOPLEFT", self:GetXY(self.curRow, self.curCol))
|
||||||
|
|||||||
Reference in New Issue
Block a user