Add files via upload

This commit is contained in:
Relationship
2026-07-16 16:54:06 +01:00
committed by GitHub
parent dca93d29af
commit 98f63bdd23
2 changed files with 32 additions and 2 deletions
+31 -1
View File
@@ -790,7 +790,37 @@ local function CreateAHUI()
local bd = cPanel.borderColor or { 0.55, 0.42, 0.22, 1 }
ahPanel:SetBackdropColor(bg[1], bg[2], bg[3], bg[4])
ahPanel:SetBackdropBorderColor(bd[1], bd[2], bd[3], bd[4])
ahPanel:SetFrameStrata("HIGH")
ahPanel:SetFrameStrata("MEDIUM") -- AH is DIALOG strata; keep panel below it
ahPanel:SetToplevel(false)
-- Draggable panel (only while AH is open)
ahPanel:SetMovable(true)
ahPanel:EnableMouse(true)
ahPanel:RegisterForDrag("LeftButton")
ahPanel:SetClampedToScreen(true)
ahPanel:SetScript("OnDragStart", function()
if AuctionFrame and AuctionFrame:IsVisible() then
this:StartMoving()
this.isMoving = true
end
end)
ahPanel:SetScript("OnDragStop", function()
if this.isMoving then
this:StopMovingOrSizing()
this.isMoving = false
local point, _, relPoint, x, y = this:GetPoint()
RelationshipsAuctionPriceDB.panelPos = {
point = point, relPoint = relPoint, x = x, y = y,
}
end
end)
-- Restore saved position (if any), otherwise keep the AH-anchored default
local savedPos = RelationshipsAuctionPriceDB and RelationshipsAuctionPriceDB.panelPos
if savedPos and savedPos.point then
ahPanel:ClearAllPoints()
ahPanel:SetPoint(savedPos.point, UIParent, savedPos.relPoint, savedPos.x, savedPos.y)
end
-- Scan button
local cBtn = C.scanButton or {}