From 0d12798a5178e86e5aa08cb3f138adc94b9622ac Mon Sep 17 00:00:00 2001 From: James Whitehead II Date: Tue, 5 Feb 2008 14:57:45 +0000 Subject: [PATCH] Added an "All Classes" checkbutton that should allow you to easily check/uncheck all of the classes --- PerfectRaid_Frames.lua | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/PerfectRaid_Frames.lua b/PerfectRaid_Frames.lua index adb49f1..672eebb 100644 --- a/PerfectRaid_Frames.lua +++ b/PerfectRaid_Frames.lua @@ -262,7 +262,16 @@ function Frames:CreateEditFrame(parent) makeCheck(L["Group 6"], "6") makeCheck(L["Group 7"], "7") makeCheck(L["Group 8"], "8") + makeCheck(L["All Classes"], "IGNORE_ALLCLASS") + PRFrameFilter_IGNORE_ALLCLASS:SetScript("OnClick", function(self) + local checked = self:GetChecked() + + for idx,button in ipairs(self.filters) do + button:SetChecked(checked) + end + end) + for idx,button in ipairs(self.filters) do if idx == 1 then button:SetPoint("TOPLEFT", title, "BOTTOMLEFT", 0, -15) @@ -567,9 +576,7 @@ function Frames:SaveEntry() local filterTbl = {} for k,v in pairs(self.filters) do - if v.value == "Party" then - partyFrame = v:GetChecked() - elseif v:GetChecked() then + if v:GetChecked() and not v.value.match("^IGNORE")then table.insert(filterTbl, v.value) end end @@ -779,4 +786,4 @@ function Frames:CreateSwatch(name, parent) swatch:SetScript("OnLeave", colorSwatchOnLeave) swatch:SetScript("OnClick", colorSwatchOnClick) return swatch -end \ No newline at end of file +end -- 1.7.9.5