WoWInterface SVN Broker_GarrisonReport

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /trunk
    from Rev 4 to Rev 5
    Reverse comparison

Rev 4 → Rev 5

Broker_GarrisonReport/Broker_GarrisonReport.toc
2,7 → 2,7
## Name: Broker_GarrisonReport
## Notes: An LDB plugin to replace the Garrison Report button on your minimap.
## Author: Seerah
## Version: 1.0.2
## Version: 1.0.3
 
LibStub\LibStub.lua
CallBackHandler-1.0\CallbackHandler-1.0.xml
Broker_GarrisonReport/report.lua
2,8 → 2,6
local strformat = string.format
local strgsub = string.gsub
local tinsert = table.insert
local garType = C_Garrison.GetLandingPageGarrisonType() --new API as of 7.0 - required for some functions now
local hasGarrison = C_Garrison.GetGarrisonInfo(garType)
local NEW_IN_PROGRESS = "%d "..strgsub(GARRISON_LANDING_IN_PROGRESS, " %- %%d", "")
local NEW_AVAILABLE = "%d "..strgsub(GARRISON_LANDING_AVAILABLE, " %- %%d", "")
local NEW_WORK_COMPLETE = " "..CAPACITANCE_WORK_COMPLETE_TOOLTIP_TITLE
13,7 → 11,7
local workOrderBuildings = {}
local missionData = {}
local underConstruction = {}
local _
local _, garType, hasGarrison
 
local GR = LibStub:GetLibrary("LibDataBroker-1.1"):NewDataObject("Broker_GarrisonReport", {
type = "data source",
172,6 → 170,10
GarrisonLandingPageMinimapButton:Hide()
hooksecurefunc(GarrisonLandingPageMinimapButton, "Show", GarrisonLandingPageMinimapButton.Hide)
elseif event == "GARRISON_UPDATE" then
if not garType then --new API as of 7.0 - required for some functions now
garType = C_Garrison.GetLandingPageGarrisonType()
C_Garrison.GetGarrisonInfo(garType)
end
hasGarrison = C_Garrison.GetGarrisonInfo(garType)
GetMissions()
ScanBuildings()
182,6 → 184,8
elseif event == "GARRISON_MISSION_FINISHED" or event == "GARRISON_MISSION_LIST_UPDATE" or event == "GARRISON_MISSION_NPC_OPENED" then
GetMissions()
else
ScanBuildings()
if garType then
ScanBuildings()
end
end
end)
\ No newline at end of file