fix: bag frames
This commit is contained in:
+20
-6
@@ -770,19 +770,33 @@ end
|
|||||||
|
|
||||||
-- OnLoad handler for bank bag slot buttons
|
-- OnLoad handler for bank bag slot buttons
|
||||||
function Guda_BankBagSlot_OnLoad(button, bagID)
|
function Guda_BankBagSlot_OnLoad(button, bagID)
|
||||||
-- Hide borders from ItemButtonTemplate
|
-- Configure border and icon inset for consistent look with main bank bag
|
||||||
local buttonName = button:GetName()
|
local buttonName = button:GetName()
|
||||||
-- Hide the normal texture border
|
|
||||||
|
-- Ensure the normal texture (border) is visible and uses the default quickslot border
|
||||||
local normalTexture = getglobal(buttonName .. "NormalTexture")
|
local normalTexture = getglobal(buttonName .. "NormalTexture")
|
||||||
if normalTexture then
|
if normalTexture then
|
||||||
normalTexture:SetTexture(nil)
|
normalTexture:SetTexture("Interface\\Buttons\\UI-Quickslot2")
|
||||||
normalTexture:Hide()
|
normalTexture:ClearAllPoints()
|
||||||
|
normalTexture:SetPoint("CENTER", button, "CENTER", 0, -1)
|
||||||
|
normalTexture:SetWidth(35)
|
||||||
|
normalTexture:SetHeight(35)
|
||||||
|
normalTexture:Show()
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Hide icon border
|
-- If the template has an IconBorder, show it as well (some clients/templates provide this)
|
||||||
local iconBorder = getglobal(buttonName .. "IconBorder")
|
local iconBorder = getglobal(buttonName .. "IconBorder")
|
||||||
if iconBorder then
|
if iconBorder then
|
||||||
iconBorder:Hide()
|
iconBorder:Show()
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Inset the icon slightly so equipped bag icons appear a bit smaller (match main bag feel)
|
||||||
|
local icon = getglobal(buttonName .. "IconTexture") or getglobal(buttonName .. "Icon")
|
||||||
|
if icon then
|
||||||
|
icon:ClearAllPoints()
|
||||||
|
icon:SetPoint("TOPLEFT", button, "TOPLEFT", 2, -2)
|
||||||
|
icon:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -2, 2)
|
||||||
|
icon:SetTexCoord(0.08, 0.92, 0.08, 0.92)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Mark this as a bag slot button, NOT an item button
|
-- Mark this as a bag slot button, NOT an item button
|
||||||
|
|||||||
+6
-6
@@ -318,7 +318,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBagMain">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBagMain">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
@@ -345,7 +345,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag5">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag5">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
@@ -372,7 +372,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag6">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag6">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
@@ -399,7 +399,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag7">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag7">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
@@ -426,7 +426,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag8">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag8">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
@@ -453,7 +453,7 @@
|
|||||||
<Anchors>
|
<Anchors>
|
||||||
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag9">
|
<Anchor point="LEFT" relativePoint="RIGHT" relativeTo="$parent_BankBag9">
|
||||||
<Offset>
|
<Offset>
|
||||||
<AbsDimension x="2" y="0"/>
|
<AbsDimension x="1" y="0"/>
|
||||||
</Offset>
|
</Offset>
|
||||||
</Anchor>
|
</Anchor>
|
||||||
</Anchors>
|
</Anchors>
|
||||||
|
|||||||
Reference in New Issue
Block a user