WoWInterface SVN NeedyGreedy

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /trunk
    from Rev 35 to Rev 34
    Reverse comparison

Rev 35 → Rev 34

NeedyGreedy.lua
133,14 → 133,6
get = "GetOnlyShowInParty",
set = "SetOnlyShowInParty",
},
hideInCombat = {
name = L["Hide in combat"],
desc = L["Only display the roll window when not in combat"],
type = "toggle",
order = 60,
get = "GetHideInCombat",
set = "SetHideInCombat",
},
},
},
}
191,9 → 183,6
-- For tracking original state of detailed loot information
local originalSpamFilterSetting = nil
 
-- For tracking combat status
local IS_IN_COMBAT = nil
 
-- Utility functions
local function sanitizePattern(pattern)
pattern = string.gsub(pattern, "%(", "%%(")
291,7 → 280,6
ACD:AddToBlizOptions("NeedyGreedy", "NeedyGreedy", nil, "general")
ACD:AddToBlizOptions("NeedyGreedy", L["Profile"], "NeedyGreedy", "profile")
self:RegisterChatCommand("needygreedy", function() InterfaceOptionsFrame_OpenToCategory("NeedyGreedy") end)
self:RegisterChatCommand("ng", function() InterfaceOptionsFrame_OpenToCategory("NeedyGreedy") end)
-- self:RegisterChatCommand("ngt", "TestItemList")
-- self.items = items
 
303,9 → 291,6
self:RegisterEvent("PARTY_MEMBERS_CHANGED")
self:RegisterEvent("START_LOOT_ROLL")
self:RegisterEvent("CHAT_MSG_LOOT")
self:RegisterEvent("PLAYER_REGEN_DISABLED")
self:RegisterEvent("PLAYER_REGEN_ENABLED")
 
self:ScheduleRepeatingTimer("ExpireItems", 1)
 
-- Delay frame display so that player does not show as offline
348,18 → 333,8
self:RefreshTooltip()
end
 
function NeedyGreedy:PLAYER_REGEN_DISABLED()
IS_IN_COMBAT = true
self:RefreshTooltip()
end
 
function NeedyGreedy:PLAYER_REGEN_ENABLED()
IS_IN_COMBAT = false
self:RefreshTooltip()
end
 
 
 
-- Chat scanning and loot recording
function NeedyGreedy:START_LOOT_ROLL(event, rollid)
local texture, name, count, quality = GetLootRollItemInfo(rollid)
860,17 → 835,8
self:RefreshTooltip()
end
 
function NeedyGreedy:GetHideInCombat(info)
return self.db.profile.hideInCombat
end
 
function NeedyGreedy:SetHideInCombat(info, hideInCombat)
self.db.profile.hideInCombat = hideInCombat
self:RefreshTooltip()
end
 
 
 
-- Detachable QTip Frames
local LibQTip = LibStub('LibQTip-1.0')
 
1189,7 → 1155,7
end
 
function NeedyGreedy:DisplayRollTableCheck()
if self:CheckOnlyShowInParty() and self:CheckShowInCombat() then
if self:CheckOnlyShowInParty() then
return true
end
 
1204,16 → 1170,8
return true
end
 
function NeedyGreedy:CheckShowInCombat()
if self.db.profile.hideInCombat and IS_IN_COMBAT then
return false
end
 
return true
end
 
 
 
-- Chat filter functions
local filter = function() return true end
local FILTER_CHAT_LOOT_MSGS = {
Localization/enUS.lua
34,7 → 34,5
L["Show only in party"] = true
L["Only display the roll window when in a party"] = true
L["You are not in a party"] = true
L["Hide in combat"] = true
L["Only display the roll window when not in combat"] = true
 
end