mirror of
https://github.com/brues-code/pfUI.git
synced 2026-09-30 11:10:00 +00:00
* "Close"-button added to GUI
This commit is contained in:
+19
-1
@@ -200,7 +200,7 @@ pfUI:RegisterModule("gui", function ()
|
||||
pfUI.gui.unlockFrames:ClearAllPoints()
|
||||
pfUI.gui.unlockFrames:SetWidth(80)
|
||||
pfUI.gui.unlockFrames:SetHeight(20)
|
||||
pfUI.gui.unlockFrames:SetPoint("BOTTOMLEFT", 0, 0)
|
||||
pfUI.gui.unlockFrames:SetPoint("BOTTOMLEFT", 0, 20)
|
||||
pfUI.gui.unlockFrames:SetBackdrop(pfUI.backdrop)
|
||||
pfUI.gui.unlockFrames.text = pfUI.gui.unlockFrames:CreateFontString("Status", "LOW", "GameFontNormal")
|
||||
pfUI.gui.unlockFrames.text:SetFont("Interface\\AddOns\\pfUI\\fonts\\arial.ttf", 9, "OUTLINE")
|
||||
@@ -213,6 +213,24 @@ pfUI:RegisterModule("gui", function ()
|
||||
pfUI.gui.UnlockFrames()
|
||||
end)
|
||||
|
||||
-- Hide GUI
|
||||
pfUI.gui.hideGUI = CreateFrame("Button", nil, pfUI.gui)
|
||||
pfUI.gui.hideGUI:ClearAllPoints()
|
||||
pfUI.gui.hideGUI:SetWidth(80)
|
||||
pfUI.gui.hideGUI:SetHeight(20)
|
||||
pfUI.gui.hideGUI:SetPoint("BOTTOMLEFT", 0, 0)
|
||||
pfUI.gui.hideGUI:SetBackdrop(pfUI.backdrop)
|
||||
pfUI.gui.hideGUI.text = pfUI.gui.hideGUI:CreateFontString("Status", "LOW", "GameFontNormal")
|
||||
pfUI.gui.hideGUI.text:SetFont("Interface\\AddOns\\pfUI\\fonts\\arial.ttf", 9, "OUTLINE")
|
||||
pfUI.gui.hideGUI.text:ClearAllPoints()
|
||||
pfUI.gui.hideGUI.text:SetAllPoints(pfUI.gui.hideGUI)
|
||||
pfUI.gui.hideGUI.text:SetPoint("CENTER", 0, 0)
|
||||
pfUI.gui.hideGUI.text:SetFontObject(GameFontWhite)
|
||||
pfUI.gui.hideGUI.text:SetText("Close")
|
||||
pfUI.gui.hideGUI:SetScript("OnClick", function()
|
||||
pfUI.gui:Hide()
|
||||
end)
|
||||
|
||||
-- Switch to default View: global
|
||||
pfUI.gui.SwitchTab(pfUI.gui.global)
|
||||
end)
|
||||
|
||||
Reference in New Issue
Block a user