WoWInterface SVN NeedyGreedy

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /trunk
    from Rev 95 to Rev 96
    Reverse comparison

Rev 95 → Rev 96

NeedyGreedy.lua
221,6 → 221,21
},
},
 
dataBrokerOptions = {
name = L["DataBroker Tooltip"],
type = "group",
args = {
suppressInRaid = {
name = L["Hide In Raid"],
desc = L["Suppress the display of the LibDataBroker tooltip when in a raid"],
type = "toggle",
order = 10,
get = "GetSuppressInRaid",
set = "SetSuppressInRaid",
},
},
},
 
}
}
 
244,6 → 259,7
resetInNewInstance = "ask",
tooltipScale = 1,
lockTooltip = false,
suppressInRaid = false,
}
}
 
327,6 → 343,7
 
-- For tracking grouped status
local IS_IN_PARTY = nil
local IS_IN_RAID = nil
 
-- For tracking ghost status
local WAS_GHOST = nil
447,6 → 464,7
local ACD = LibStub("AceConfigDialog-3.0")
ACD:AddToBlizOptions("NeedyGreedy", "NeedyGreedy", nil, "general")
ACD:AddToBlizOptions("NeedyGreedy", L["Detached Tooltip"], "NeedyGreedy", "detachedTooltipOptions")
ACD:AddToBlizOptions("NeedyGreedy", L["DataBroker Tooltip"], "NeedyGreedy", "dataBrokerOptions")
ACD:AddToBlizOptions("NeedyGreedy", L["Profile"], "NeedyGreedy", "profile")
 
-- Register slash options table
463,6 → 481,7
self:RegisterEvent("PLAYER_REGEN_DISABLED")
self:RegisterEvent("PLAYER_REGEN_ENABLED")
self:RegisterEvent("PLAYER_ALIVE")
self:RegisterEvent("RAID_ROSTER_UPDATE")
 
self:ScheduleRepeatingTimer("ExpireItems", 10)
 
539,6 → 558,7
 
elseif (GetNumPartyMembers() == 0 and GetNumRaidMembers() == 0) then
IS_IN_PARTY = false
IS_IN_RAID = false
 
if self.db.profile.showOnParty and self.db.profile.detachedTooltip and self.db.profile.displayStatus then
self.db.profile.displayStatus = false
569,8 → 589,16
end
end
 
function NeedyGreedy:RAID_ROSTER_UPDATE()
if GetNumRaidMembers() > 0 then
IS_IN_RAID = true
else
IS_IN_RAID = false
end
end
 
 
 
-- Chat scanning and loot recording
function NeedyGreedy:START_LOOT_ROLL(event, rollid, rollTime)
local texture, name, count, quality = GetLootRollItemInfo(rollid)
1167,8 → 1195,17
self:RefreshTooltip()
end
 
function NeedyGreedy:GetSuppressInRaid(info)
return self.db.profile.suppressInRaid
end
 
function NeedyGreedy:SetSuppressInRaid(info, suppressInRaid)
self.db.profile.suppressInRaid = suppressInRaid
self:RefreshTooltip()
end
 
 
 
-- QTip Frames
local LibQTip = LibStub('LibQTip-1.0')
local COL_MIN_WIDTH = 60
1538,8 → 1575,10
function NeedyGreedy:BuildDBReportTooltip(tooltip)
tooltip:Clear()
self:AddHeaderText(tooltip)
self:PopulateReportTooltip(tooltip)
self:AddPagerArrows(tooltip)
if self:DisplayLDBTTCheck() then
self:PopulateReportTooltip(tooltip)
self:AddPagerArrows(tooltip)
end
self:AddInfoText(tooltip)
end
 
1611,8 → 1650,26
return true
end
 
function NeedyGreedy:DisplayLDBTTCheck()
if self:CheckSuppressInRaid() then
return false
end
 
return true
end
 
function NeedyGreedy:CheckSuppressInRaid()
if IS_IN_RAID and self.db.profile.suppressInRaid then
return true
end
 
return false
end
 
 
 
 
 
-- Chat filter functions
local FILTER_CHAT_LOOT_MSGS = {
--LOOT_ROLL_ALL_PASSED,
Localization/enUS.lua
57,5 → 57,8
L["Detached Tooltip"] = true
L["Lock Tooltip"] = true
L["Adjust the position of the detached tooltip"] = true
L["DataBroker Tooltip"] = true
L["Hide In Raid"] = true
L["Suppress the display of the LibDataBroker tooltip when in a raid"] = true
 
end