mirror of
https://github.com/brues-code/pfUI.git
synced 2026-10-31 16:06:57 +00:00
Toggle visibility with SetShown instead of Show/Hide branches
Each if/else that only showed one object in one branch and hid it in the other is now ClassicAPI's SetShown, which shows on any truthy value. 21 sites across 10 modules.
This commit is contained in:
@@ -1,10 +1,6 @@
|
||||
pfUI:RegisterModule("farmmode", function ()
|
||||
local function ToggleFarmMode()
|
||||
if pfUI.farmmap:IsShown() then
|
||||
pfUI.farmmap:Hide()
|
||||
else
|
||||
pfUI.farmmap:Show()
|
||||
end
|
||||
pfUI.farmmap:SetShown(not pfUI.farmmap:IsShown())
|
||||
end
|
||||
|
||||
local function MoveNodes(layer)
|
||||
|
||||
Reference in New Issue
Block a user