Shuffle codes about
This commit is contained in:
parent
affdbef5c1
commit
36c5228bac
15
Init.lua
15
Init.lua
|
@ -16,26 +16,20 @@ end
|
|||
|
||||
|
||||
function ns.OnLoad()
|
||||
Hide(MerchantNextPageButton)
|
||||
Hide(MerchantPrevPageButton)
|
||||
Hide(MerchantPageText)
|
||||
|
||||
|
||||
local GVS = ns.NewMainFrame()
|
||||
GVS:SetWidth(315)
|
||||
GVS:SetHeight(294)
|
||||
GVS:SetPoint("TOPLEFT", MerchantFrame, 8, -67)
|
||||
GVS:Hide()
|
||||
|
||||
|
||||
-- Reanchor the buyback button, it acts weird when switching tabs otherwise...
|
||||
MerchantBuyBackItem:ClearAllPoints()
|
||||
MerchantBuyBackItem:SetPoint("BOTTOMRIGHT", -7, 33)
|
||||
|
||||
|
||||
-- The little class select dropdown show trigget a refresh
|
||||
hooksecurefunc("SetMerchantFilter", function() GVS:GetScript("OnShow")(GVS) end)
|
||||
|
||||
|
||||
-- Force show when we're loaded on demand and the tab is already selected
|
||||
if MerchantFrame:IsVisible() and MerchantFrame.selectedTab == 1 then
|
||||
GVS:Show()
|
||||
end
|
||||
|
@ -43,6 +37,11 @@ function ns.OnLoad()
|
|||
-- Reparent the first 10 MerchantItem frames, so they only appear for buyback
|
||||
for i=1,10 do _G["MerchantItem"..i]:SetParent(MerchantItem11) end
|
||||
|
||||
-- Hide frames we don't need now
|
||||
Hide(MerchantNextPageButton)
|
||||
Hide(MerchantPrevPageButton)
|
||||
Hide(MerchantPageText)
|
||||
|
||||
-- Clean up our frame factories
|
||||
for i,v in pairs(ns) do if i:match("^New") then ns[i] = nil end end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue