mirror of
https://github.com/brues-code/pfUI.git
synced 2026-10-30 23:46:57 +00:00
Use ClassicAPI's nop for empty functions
This commit is contained in:
@@ -128,7 +128,7 @@ pfUI:RegisterModule("addoncompat", function ()
|
||||
{T["Yes"], function()
|
||||
ReloadUI()
|
||||
end},
|
||||
{T["No"], function() end},
|
||||
{T["No"], nop},
|
||||
nil)
|
||||
end
|
||||
end
|
||||
|
||||
+1
-1
@@ -761,7 +761,7 @@ pfUI:RegisterModule("gui", function ()
|
||||
local defval = "["..T["Search"].."]"
|
||||
|
||||
-- initialize search window
|
||||
CreateGUIEntry(defval, nil, function() end)
|
||||
CreateGUIEntry(defval, nil, nop)
|
||||
pfUI.gui.frames[defval]:Click()
|
||||
|
||||
local scroll = pfUI.gui.frames[defval].area.scroll.content
|
||||
|
||||
+10
-10
@@ -20,8 +20,8 @@ pfUI:RegisterSkin("Help", function ()
|
||||
-- HelpFrameHome
|
||||
StripTextures(HelpFrameHomeIssues)
|
||||
SkinButton(HelpFrameHomeIssues)
|
||||
HelpFrameHomeIssues:SetScript("OnMouseUp", function() end)
|
||||
HelpFrameHomeIssues:SetScript("OnMouseDown", function() end)
|
||||
HelpFrameHomeIssues:SetScript("OnMouseUp", nop)
|
||||
HelpFrameHomeIssues:SetScript("OnMouseDown", nop)
|
||||
|
||||
SkinButton(HelpFrameHomeCancel)
|
||||
|
||||
@@ -49,13 +49,13 @@ pfUI:RegisterSkin("Help", function ()
|
||||
-- HelpFrameGeneral
|
||||
StripTextures(HelpFrameGeneralButton)
|
||||
SkinButton(HelpFrameGeneralButton)
|
||||
HelpFrameGeneralButton:SetScript("OnMouseUp", function() end)
|
||||
HelpFrameGeneralButton:SetScript("OnMouseDown", function() end)
|
||||
HelpFrameGeneralButton:SetScript("OnMouseUp", nop)
|
||||
HelpFrameGeneralButton:SetScript("OnMouseDown", nop)
|
||||
|
||||
StripTextures(HelpFrameGeneralButton2)
|
||||
SkinButton(HelpFrameGeneralButton2)
|
||||
HelpFrameGeneralButton2:SetScript("OnMouseUp", function() end)
|
||||
HelpFrameGeneralButton2:SetScript("OnMouseDown", function() end)
|
||||
HelpFrameGeneralButton2:SetScript("OnMouseUp", nop)
|
||||
HelpFrameGeneralButton2:SetScript("OnMouseDown", nop)
|
||||
|
||||
SkinButton(HelpFrameGeneralCancel)
|
||||
|
||||
@@ -69,13 +69,13 @@ pfUI:RegisterSkin("Help", function ()
|
||||
|
||||
StripTextures(HelpFrameVerbalHarassmentButton)
|
||||
SkinButton(HelpFrameVerbalHarassmentButton)
|
||||
HelpFrameVerbalHarassmentButton:SetScript("OnMouseUp", function() end)
|
||||
HelpFrameVerbalHarassmentButton:SetScript("OnMouseDown", function() end)
|
||||
HelpFrameVerbalHarassmentButton:SetScript("OnMouseUp", nop)
|
||||
HelpFrameVerbalHarassmentButton:SetScript("OnMouseDown", nop)
|
||||
|
||||
StripTextures(HelpFramePhysicalHarassmentButton)
|
||||
SkinButton(HelpFramePhysicalHarassmentButton)
|
||||
HelpFramePhysicalHarassmentButton:SetScript("OnMouseUp", function() end)
|
||||
HelpFramePhysicalHarassmentButton:SetScript("OnMouseDown", function() end)
|
||||
HelpFramePhysicalHarassmentButton:SetScript("OnMouseUp", nop)
|
||||
HelpFramePhysicalHarassmentButton:SetScript("OnMouseDown", nop)
|
||||
|
||||
SkinButton(HelpFrameHarassmentCancel)
|
||||
|
||||
|
||||
@@ -76,8 +76,8 @@ pfUI:RegisterSkin("Books", function ()
|
||||
ItemTextScrollFrameScrollBarScrollUpButton:Show()
|
||||
ItemTextScrollFrameScrollBarScrollDownButton:Show()
|
||||
|
||||
ItemTextScrollFrame.Show = function(self) end
|
||||
ItemTextScrollFrame.Hide = function(self) end
|
||||
ItemTextScrollFrame.Show = nop
|
||||
ItemTextScrollFrame.Hide = nop
|
||||
ItemTextScrollFrameScrollBar.Show = function(self) self.thumb:Show() end
|
||||
ItemTextScrollFrameScrollBar.Hide = function(self) self.thumb:Hide() end
|
||||
ItemTextScrollFrameScrollBarScrollUpButton.Show = function(self) if self:GetParent():GetValue() ~= 0 then self:Enable() end end
|
||||
|
||||
@@ -34,8 +34,8 @@ pfUI:RegisterSkin("KeyBindings", function ()
|
||||
local button = _G["KeyBindingFrameBinding"..key.."Key"..btn.."Button"]
|
||||
StripTextures(button)
|
||||
SkinButton(button)
|
||||
button:SetScript("OnMouseDown", function() end)
|
||||
button:SetScript("OnMouseUp", function() end)
|
||||
button:SetScript("OnMouseDown", nop)
|
||||
button:SetScript("OnMouseUp", nop)
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
@@ -23,7 +23,7 @@ pfUI:RegisterSkin("Options - Interface", function ()
|
||||
SkinCollapseButton(toggle)
|
||||
toggle:SetPushedTexture("")
|
||||
toggle:SetHighlightTexture("")
|
||||
toggle.SetPushedTexture = function() end
|
||||
toggle.SetPushedTexture = nop
|
||||
end
|
||||
|
||||
-- ClassicAPI's own pages (Options\Panel.lua) number their controls
|
||||
|
||||
Reference in New Issue
Block a user