# HG changeset patch
# User Nenue
# Date 1459587714 14400
# Node ID 8238cddaddb1b93e7bbf6c70f665b8597c68e20b
# Parent fb80e365bab34ca5b0af893637378c4ea387efba
ObjectiveUI
- fillers for 'Hidden' objective widgets
diff -r fb80e365bab3 -r 8238cddaddb1 ObjectiveFrame.lua
--- a/ObjectiveFrame.lua Sat Apr 02 03:23:12 2016 -0400
+++ b/ObjectiveFrame.lua Sat Apr 02 05:01:54 2016 -0400
@@ -33,7 +33,7 @@
local titleOutline, textOutline = "OUTLINE", "OUTLINE"
local titleSpacing, textSpacing = 4, 3
local textIndent = 5
-local wrapperMaxWidth, wrapperMaxHeight = 280, 490 -- these are the hard bounds, actual *Height variables are changed
+local wrapperMaxWidth, wrapperMaxHeight = 270, 490 -- these are the hard bounds, actual *Height variables are changed
local wrapperHeadFont, wrapperHeadSize, wrapperHeadOutline = [[Interface\Addons\SharedMedia_MyMedia\font\ArchivoNarrow-Bold.ttf]], 16, 'NONE'
local headerFont, headerSize, headerHeight = [[Interface\Addons\SharedMedia_MyMedia\font\ArchivoNarrow-Bold.ttf]], 18, 24
local headerOutline, headerColor, headerSpacing = 'OUTLINE', {1,1,1,1}, 2
@@ -127,7 +127,7 @@
--- xp bar
XPBar:SetWidth(wrapperWidth - Wrapper.close:GetWidth())
- XPBar.bg:SetAllPoints(XPBar)
+ XPBar.statusbg:SetAllPoints(XPBar)
XPBar:RegisterEvent('DISABLE_XP_GAIN')
XPBar:RegisterEvent('ENABLE_XP_GAIN')
XPBar:SetScript('OnEvent', mod.UpdateXP)
@@ -145,7 +145,7 @@
self:RegisterEvent('PLAYER_XP_UPDATE')
self:RegisterEvent('PLAYER_LEVEL_UP')
self:RegisterEvent('PLAYER_UPDATE_RESTING')
- self.bg:SetTexture(0,0,0,.25)
+ self.statusbg:SetTexture(0,0,0,.25)
self:Show()
end
@@ -153,7 +153,7 @@
self:UnregisterEvent('PLAYER_XP_UPDATE')
self:UnregisterEvent('PLAYER_LEVEL_UP')
self:UnregisterEvent('PLAYER_UPDATE_RESTING')
- self.bg:SetTexture(0.5,0.5,0.5,0.5)
+ self.statusbg:SetTexture(0.5,0.5,0.5,0.5)
self:Hide()
end
@@ -169,7 +169,7 @@
local xp = UnitXP('player')
local xpmax = UnitXPMax('player')
local rest = GetXPExhaustion()
- self.fg:SetWidth((xp/xpmax) * self:GetWidth())
+ self.foreground:SetWidth((xp/xpmax) * self:GetWidth())
if rest then
self.rested:ClearAllPoints()
if xp == 0 then
@@ -190,9 +190,9 @@
end
if IsResting() then
- self.bg:SetTexture(.2,.8,.2,.5)
+ self.statusbg:SetTexture(.2,.8,.2,.5)
else
- self.bg:SetTexture(0,0,0,.25)
+ self.statusbg:SetTexture(0,0,0,.25)
end
self.xpText:SetText(xp .. '/'.. xpmax .. (rest and (' ('..tostring(rest)..')') or ''))
end
diff -r fb80e365bab3 -r 8238cddaddb1 ObjectiveTracker.xml
--- a/ObjectiveTracker.xml Sat Apr 02 03:23:12 2016 -0400
+++ b/ObjectiveTracker.xml Sat Apr 02 05:01:54 2016 -0400
@@ -104,7 +104,7 @@
-
+
diff -r fb80e365bab3 -r 8238cddaddb1 ObjectiveUI.lua
--- a/ObjectiveUI.lua Sat Apr 02 03:23:12 2016 -0400
+++ b/ObjectiveUI.lua Sat Apr 02 05:01:54 2016 -0400
@@ -383,4 +383,12 @@
self.fg:Show()
self.fg:SetWidth((self.bg:GetWidth()-4) * (quantity / requiredQuantity))
end
+end
+
+
+mod.InitializeWidget.Hidden = function (self)
+ self.height = 0
+end
+mod.UpdateWidget.Hidden = function (self)
+ self.height= 0
end
\ No newline at end of file
diff -r fb80e365bab3 -r 8238cddaddb1 ObjectiveWidgets.xml
--- a/ObjectiveWidgets.xml Sat Apr 02 03:23:12 2016 -0400
+++ b/ObjectiveWidgets.xml Sat Apr 02 05:01:54 2016 -0400
@@ -67,4 +67,28 @@
+
+
+
+
+
+ self.widgetType = 'Hidden'
+ self.lines = 0
+ Veneer.ObjectiveTracker.RegisterWidget(self)
+
+
+ Veneer.ObjectiveTracker.InitializeWidget(self)
+
+
+ Veneer.ObjectiveTracker.ReleaseWidget(self)
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file