Commit a9577cfd authored by Merathilis's avatar Merathilis

Use GameTooltip_Hide instead making an own function for it.

parent a3b2e4cd
......@@ -148,10 +148,6 @@ function B:Tooltip_Show()
GameTooltip:Show()
end
function B:Tooltip_Hide()
_G.GameTooltip:Hide()
end
function B:DisableBlizzard()
_G.BankFrame:UnregisterAllEvents();
......@@ -661,7 +657,7 @@ function B:UpdateSlot(bagID, slotID)
SetItemButtonDesaturated(slot, slot.locked or slot.junkDesaturate);
if _G.GameTooltip:GetOwner() == slot and not slot.hasItem then
B:Tooltip_Hide()
GameTooltip_Hide()
end
end
......@@ -1715,7 +1711,7 @@ function B:ContructContainerFrame(name, isBank)
f.reagentToggle:StyleButton(nil, true)
f.reagentToggle.ttText = L["Show/Hide Reagents"];
f.reagentToggle:SetScript("OnEnter", self.Tooltip_Show)
f.reagentToggle:SetScript("OnLeave", self.Tooltip_Hide)
f.reagentToggle:SetScript("OnLeave", GameTooltip_Hide)
f.reagentToggle:SetScript("OnClick", function()
PlaySound(841) --IG_CHARACTER_INFO_TAB
B:ShowBankTab(f, f.holderFrame:IsShown())
......@@ -1774,7 +1770,7 @@ function B:ContructContainerFrame(name, isBank)
f.depositButton:StyleButton(nil, true)
f.depositButton.ttText = L["Deposit Reagents"]
f.depositButton:SetScript("OnEnter", self.Tooltip_Show)
f.depositButton:SetScript("OnLeave", self.Tooltip_Hide)
f.depositButton:SetScript("OnLeave", GameTooltip_Hide)
f.depositButton:SetScript('OnClick', function()
PlaySound(852) --IG_MAINMENU_OPTION
DepositReagentBank()
......@@ -1793,7 +1789,7 @@ function B:ContructContainerFrame(name, isBank)
f.depositButtonBank:StyleButton(nil, true)
f.depositButtonBank.ttText = L["Deposit Reagents"]
f.depositButtonBank:SetScript("OnEnter", self.Tooltip_Show)
f.depositButtonBank:SetScript("OnLeave", self.Tooltip_Hide)
f.depositButtonBank:SetScript("OnLeave", GameTooltip_Hide)
f.depositButtonBank:SetScript('OnClick', function()
PlaySound(852) --IG_MAINMENU_OPTION
DepositReagentBank()
......@@ -1814,7 +1810,7 @@ function B:ContructContainerFrame(name, isBank)
f.bagsButton.ttText = L["Toggle Bags"]
f.bagsButton.ttText2 = format("|cffFFFFFF%s|r", L["Right Click the bag icon to assign a type of item to this bag."])
f.bagsButton:SetScript("OnEnter", self.Tooltip_Show)
f.bagsButton:SetScript("OnLeave", self.Tooltip_Hide)
f.bagsButton:SetScript("OnLeave", GameTooltip_Hide)
f.bagsButton:SetScript('OnClick', function()
local numSlots = GetNumBankSlots()
PlaySound(852) --IG_MAINMENU_OPTION
......@@ -1838,7 +1834,7 @@ function B:ContructContainerFrame(name, isBank)
f.purchaseBagButton:StyleButton(nil, true)
f.purchaseBagButton.ttText = L["Purchase Bags"]
f.purchaseBagButton:SetScript("OnEnter", self.Tooltip_Show)
f.purchaseBagButton:SetScript("OnLeave", self.Tooltip_Hide)
f.purchaseBagButton:SetScript("OnLeave", GameTooltip_Hide)
f.purchaseBagButton:SetScript("OnClick", function()
local _, full = GetNumBankSlots()
if full then
......@@ -1937,7 +1933,7 @@ function B:ContructContainerFrame(name, isBank)
f.bagsButton.ttText = L["Toggle Bags"]
f.bagsButton.ttText2 = format("|cffFFFFFF%s|r", L["Right Click the bag icon to assign a type of item to this bag."])
f.bagsButton:SetScript("OnEnter", self.Tooltip_Show)
f.bagsButton:SetScript("OnLeave", self.Tooltip_Hide)
f.bagsButton:SetScript("OnLeave", GameTooltip_Hide)
f.bagsButton:SetScript('OnClick', function() ToggleFrame(f.ContainerHolder) end)
--Vendor Grays
......@@ -1954,7 +1950,7 @@ function B:ContructContainerFrame(name, isBank)
f.vendorGraysButton:StyleButton(nil, true)
f.vendorGraysButton.ttText = L["Vendor / Delete Grays"]
f.vendorGraysButton:SetScript("OnEnter", self.Tooltip_Show)
f.vendorGraysButton:SetScript("OnLeave", self.Tooltip_Hide)
f.vendorGraysButton:SetScript("OnLeave", GameTooltip_Hide)
f.vendorGraysButton:SetScript("OnClick", B.VendorGrayCheck)
--Search
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment