Quantcast

many fixes

Steven Jackson [07-05-15 - 20:11]
many fixes
Filename
SVUITheme_Simple/SVUITheme_Simple.lua
SVUI_!Core/system/_docklets/garrison.lua
SVUI_!Core/system/_docklets/misc.lua
SVUI_!Core/system/_reports/reputation.lua
SVUI_!Core/system/_reports/tokens.lua
SVUI_!Core/system/core.lua
SVUI_!Core/system/dock.lua
SVUI_!Core/system/dropdown.lua
SVUI_!Core/system/funstuff.lua
SVUI_!Core/system/misc.lua
SVUI_ActionBars/SVUI_ActionBars.lua
SVUI_Chat/SVUI_Chat.lua
SVUI_QuestTracker/SVUI_QuestTracker.lua
SVUI_QuestTracker/components/achievements.lua
SVUI_QuestTracker/components/active.lua
SVUI_QuestTracker/components/quests.lua
SVUI_UnitFrames/frames.lua
diff --git a/SVUITheme_Simple/SVUITheme_Simple.lua b/SVUITheme_Simple/SVUITheme_Simple.lua
index d6169a8..f83c945 100644
--- a/SVUITheme_Simple/SVUITheme_Simple.lua
+++ b/SVUITheme_Simple/SVUITheme_Simple.lua
@@ -73,6 +73,11 @@ local _RefreshZoneText = function(self)
 	end
 end

+local UpdateBackdrop = function(self)
+	local current = SV.Dock.private.Opacity[self:GetName()];
+	self:SetAlpha(current or 1);
+end
+
 local _SetThemedBackdrop = function(frame, isBottom)
 	local backdrop = CreateFrame("Frame", nil, frame)
 	backdrop:SetAllPoints(frame)
@@ -94,6 +99,8 @@ local _SetThemedBackdrop = function(frame, isBottom)
 	backdrop:SetBackdropColor(0,0,0,0.5);
 	backdrop:SetBackdropBorderColor(0,0,0,0.8);

+	frame.UpdateBackdrop = UpdateBackdrop
+
 	return backdrop
 end

diff --git a/SVUI_!Core/system/_docklets/garrison.lua b/SVUI_!Core/system/_docklets/garrison.lua
index e93a851..6335624 100644
--- a/SVUI_!Core/system/_docklets/garrison.lua
+++ b/SVUI_!Core/system/_docklets/garrison.lua
@@ -236,6 +236,9 @@ local SetGarrisonTooltip = function(self)
 	local name, amount, tex, week, weekmax, maxed, discovered = GetCurrencyInfo(824)
 	local texStr = ("\124T%s:12\124t %d"):format(tex, amount)
 	GameTooltip:AddDoubleLine(name, texStr, 1, 1, 0, 1, 1, 1)
+	name, amount, tex, week, weekmax, maxed, discovered = GetCurrencyInfo(1101)
+	texStr = ("\124T%s:12\124t %d"):format(tex, amount)
+	GameTooltip:AddDoubleLine(name, texStr, 1, 1, 0, 1, 1, 1)
 	GetActiveMissions()
 	GetBuildingData()
 	if(self.StopAlert) then
diff --git a/SVUI_!Core/system/_docklets/misc.lua b/SVUI_!Core/system/_docklets/misc.lua
index c22b036..4ab6b1f 100644
--- a/SVUI_!Core/system/_docklets/misc.lua
+++ b/SVUI_!Core/system/_docklets/misc.lua
@@ -75,8 +75,10 @@ local MOD = SV.Dock;
 LOCALS
 ##########################################################
 ]]--
-local HEARTH_SPELLS = {556,50977,18960,126892}
-local HEARTH_ITEMS = {110560}
+local HEARTH_SPELLS = {556,50977,18960,126892};
+local HEARTH_ITEMS = {6948,110560,64488,54452,93672,28585};
+local HEARTH_LEFT_CLICK, HEARTH_RIGHT_CLICK = 6948, 110560;
+local HEARTH_HEADER = "HearthStone";

 local function GetMacroCooldown(itemID)
 	local start,duration = GetItemCooldown(itemID)
@@ -106,6 +108,56 @@ local function GetMacroCooldown(itemID)
 	end
 end

+local function GetHearthOption(selected)
+	local option,found;
+	for i = 1, #HEARTH_SPELLS do
+		if(not found) then
+			local optionID = HEARTH_SPELLS[i];
+			if(optionID == selected) then
+				found = true;
+				if(IsSpellKnown(optionID)) then
+					option = GetSpellInfo(optionID);
+				end
+			end
+		end
+	end
+	if(not option) then
+		for i = 1, #HEARTH_ITEMS do
+			if(not found) then
+				local optionID = HEARTH_ITEMS[i];
+				if(optionID == selected) then
+					found = true;
+					local test = GetItemInfo(optionID);
+					if(test and type(test) == 'string') then
+						local owned = GetItemCount(optionID,false)
+						if(owned and owned > 0) then
+							option = test;
+						end
+					end
+				end
+			end
+		end
+	end
+	return option;
+end
+
+local function UpdateHearthOptions()
+	HEARTH_LEFT_CLICK = SV.db.Dock.hearthOptions.left;
+	HEARTH_RIGHT_CLICK = SV.db.Dock.hearthOptions.right;
+
+	local leftClick = GetHearthOption(HEARTH_LEFT_CLICK);
+	if(leftClick and type(leftClick) == "string") then
+		SVUI_Hearth:SetAttribute("tipText", leftClick)
+		SVUI_Hearth:SetAttribute("macrotext1", "/use [nomod]" .. leftClick)
+	end
+
+	local rightClick = GetHearthOption(HEARTH_RIGHT_CLICK);
+	if(rightClick and type(rightClick) == "string") then
+		SVUI_Hearth:SetAttribute("tipExtraText", rightClick)
+		SVUI_Hearth:SetAttribute("macrotext2", "/use [nomod]" .. rightClick)
+	end
+end
+
 local Hearth_OnEnter = function(self)
 	GameTooltip:AddLine(HELPFRAME_STUCK_HEARTHSTONE_HEADER, 1, 1, 0)
 	GameTooltip:AddLine(" ", 1, 1, 1)
@@ -121,6 +173,69 @@ local Hearth_OnEnter = function(self)
 	if(text2 and text2 ~= "") then
 		GameTooltip:AddDoubleLine("[Right-Click]", text2, 0, 1, 0, 1, 1, 1)
 	end
+	GameTooltip:AddLine(" ", 1, 1, 1)
+	GameTooltip:AddDoubleLine("|cff0099FFSHIFT|r + Left-Click", "Left Click Options", 0, 1, 0, 0.5, 1, 0.5)
+	if(text2 and text2 ~= "") then
+		GameTooltip:AddDoubleLine("|cff0099FFSHIFT|r + Right-Click", "Right Click Options", 0, 1, 0, 0.5, 1, 0.5)
+	end
+end
+
+local Hearth_OnShiftLeftClick = function(self)
+	if(IsShiftKeyDown()) then
+
+		local t = {};
+		tinsert(t, { title = "Left Click Options", divider = true });
+		for i = 1, #HEARTH_SPELLS do
+			local optionID = HEARTH_SPELLS[i];
+			if(IsSpellKnown(optionID)) then
+				local hearthOption = GetSpellInfo(optionID);
+				if(hearthOption and type(hearthOption) == 'string') then
+					tinsert(t, { text = hearthOption, func = function() SV.db.Dock.hearthOptions.left = optionID; UpdateHearthOptions(); end });
+				end
+			end
+		end
+		for i = 1, #HEARTH_ITEMS do
+			local optionID = HEARTH_ITEMS[i];
+			local hearthOption = GetItemInfo(optionID);
+			if(hearthOption and type(hearthOption) == 'string') then
+				local owned = GetItemCount(optionID,false)
+				if(owned and owned > 0) then
+					tinsert(t, { text = hearthOption, func = function() SV.db.Dock.hearthOptions.left = optionID; UpdateHearthOptions(); end });
+				end
+			end
+		end
+
+		SV.Dropdown:Open(self, t, HEARTH_HEADER);
+	end
+end
+
+local Hearth_OnShiftRightClick = function(self)
+	if(IsShiftKeyDown()) then
+
+		local t = {};
+		tinsert(t, { title = "Right Click Options", divider = true });
+		for i = 1, #HEARTH_SPELLS do
+			local optionID = HEARTH_SPELLS[i];
+			if(IsSpellKnown(optionID)) then
+				local hearthOption = GetSpellInfo(optionID);
+				if(hearthOption and type(hearthOption) == 'string') then
+					tinsert(t, { text = hearthOption, func = function() SV.db.Dock.hearthOptions.right = optionID; UpdateHearthOptions(); end });
+				end
+			end
+		end
+		for i = 1, #HEARTH_ITEMS do
+			local optionID = HEARTH_ITEMS[i];
+			local hearthOption = GetItemInfo(optionID);
+			if(hearthOption and type(hearthOption) == 'string') then
+				local owned = GetItemCount(optionID,false)
+				if(owned and owned > 0) then
+					tinsert(t, { text = hearthOption, func = function() SV.db.Dock.hearthOptions.right = optionID; UpdateHearthOptions(); end });
+				end
+			end
+		end
+
+		SV.Dropdown:Open(self, t, HEARTH_HEADER);
+	end
 end

 local SpecSwap_OnClick = function(self)
@@ -185,35 +300,18 @@ local function LoadMiscTools()
 	end

 	-- HEARTH BUTTON
+	HEARTH_HEADER = GetHearthOption(6948);
+
 	if(SV.db.Dock.dockTools.hearth) then
-		local hearthStone = GetItemInfo(6948);
-		if(hearthStone and type(hearthStone) == "string") then
-			local hearth = SV.Dock:SetDockButton("BottomLeft", hearthStone, "SVUI_Hearth", SV.media.dock.hearthIcon, Hearth_OnEnter, "SecureActionButtonTemplate")
+		if(HEARTH_HEADER and type(HEARTH_HEADER) == "string") then
+			local hearth = SV.Dock:SetDockButton("BottomLeft", HEARTH_HEADER, "SVUI_Hearth", SV.media.dock.hearthIcon, Hearth_OnEnter, "SecureActionButtonTemplate")
 			hearth.Icon:SetTexCoord(0,0.5,0,1)
 			hearth:SetAttribute("type1", "macro")
-			hearth:SetAttribute("macrotext1", "/use [nomod]" .. hearthStone)
-			local hasRightClick = false;
-			for i = 1, #HEARTH_SPELLS do
-				if(IsSpellKnown(HEARTH_SPELLS[i])) then
-					local rightClickSpell = GetSpellInfo(HEARTH_SPELLS[i])
-					hearth:SetAttribute("tipExtraText", rightClickSpell)
-					hearth:SetAttribute("type2", "macro")
-					hearth:SetAttribute("macrotext2", "/use [nomod] " .. rightClickSpell)
-					hasRightClick = true;
-				end
-			end
-			--HEARTH_ITEMS
-			if(not hasRightClick) then
-				for i = 1, #HEARTH_ITEMS do
-					local rightClickItem = GetItemInfo(HEARTH_ITEMS[i])
-					if(rightClickItem) then
-						hearth:SetAttribute("tipExtraText", rightClickItem)
-						hearth:SetAttribute("type2", "macro")
-						hearth:SetAttribute("macrotext2", "/use [nomod] " .. rightClickItem)
-						hasRightClick = true;
-					end
-				end
-			end
+			hearth:SetAttribute("type2", "macro")
+
+			UpdateHearthOptions();
+
+			hearth:SetClickCallbacks(Hearth_OnShiftLeftClick, Hearth_OnShiftRightClick)
 		end
 	end

diff --git a/SVUI_!Core/system/_reports/reputation.lua b/SVUI_!Core/system/_reports/reputation.lua
index 8a726a8..2f74eed 100644
--- a/SVUI_!Core/system/_reports/reputation.lua
+++ b/SVUI_!Core/system/_reports/reputation.lua
@@ -54,7 +54,9 @@ local function TruncateString(value)
         return value
     end
 end
--- name, description, standingID, barMin, barMax, barValue, _, _, _, _, hasRep, isWatched, isChild
+
+local sort_menu_fn = function(a,b) return a.text < b.text end;
+
 local function CacheRepData(data)
 	twipe(data)
 	for factionIndex = 1, GetNumFactions() do
@@ -69,7 +71,7 @@ local function CacheRepData(data)
 			tinsert(data, {text = factionName, func = fn})
 		end
 	end
-	tsort(data, function(a,b) return a.text < b.text end)
+	tsort(data, sort_menu_fn)
 end
 --[[
 ##########################################################
diff --git a/SVUI_!Core/system/_reports/tokens.lua b/SVUI_!Core/system/_reports/tokens.lua
index 87692d5..4513ffe 100644
--- a/SVUI_!Core/system/_reports/tokens.lua
+++ b/SVUI_!Core/system/_reports/tokens.lua
@@ -14,6 +14,7 @@ local select 	= _G.select;
 local tinsert 	= _G.tinsert;
 local table     = _G.table;
 local twipe     = table.wipe;
+local tsort     = table.sort;
 local GetCurrencyInfo           = _G.GetCurrencyInfo;
 local GetNumWatchedTokens       = _G.GetNumWatchedTokens;
 local GetBackpackCurrencyInfo   = _G.GetBackpackCurrencyInfo;
@@ -38,6 +39,8 @@ local TEXT_PATTERN = "\124T%s:12\124t %s";
 local playerName = UnitName("player");
 local playerRealm = GetRealmName();

+local sort_menu_fn = function(a,b) return a.text < b.text end;
+
 local Tokens_OnEvent = function(self, event, ...)
     if(not IsLoggedIn() or (not self)) then return end
     local id = self.TokenKey or 738;
@@ -47,14 +50,13 @@ local Tokens_OnEvent = function(self, event, ...)
 end

 local function AddToTokenMenu(self, id, key)
-  local name, _, tex, _, _, _, _ = GetCurrencyInfo(id)
-  local itemName = "\124T"..tex..":12\124t "..name;
+  local itemName, _, tex, _, _, _, _ = GetCurrencyInfo(id)
   local fn = function()
     Reports.Accountant["tokens"][playerName][key] = id;
     self.TokenKey = id
     Tokens_OnEvent(self)
   end
-  tinsert(self.InnerData, {text = itemName, func = fn});
+  tinsert(self.InnerData, {text = itemName, icon = "\124T"..tex..":12\124t ", func = fn});
 end

 local function CacheTokenData(self)
@@ -110,6 +112,9 @@ local function CacheTokenData(self)
     AddToTokenMenu(self, 789, key)
     AddToTokenMenu(self, 823, key)
     AddToTokenMenu(self, 824, key)
+    AddToTokenMenu(self, 1101, key)
+
+    tsort(self.InnerData, sort_menu_fn)
 end

 local function TokenInquiry(id, weekly, capped)
@@ -160,7 +165,7 @@ Report.OnEvent = Tokens_OnEvent;

 Report.OnClick = function(self, button)
   CacheTokenData(self);
-  SV.Dropdown:Open(self, self.InnerData, "Select Currency")
+  SV.Dropdown:Open(self, self.InnerData, "Select Currency", 200)
 end

 Report.OnEnter = function(self)
@@ -180,6 +185,7 @@ Report.OnEnter = function(self)
   Reports.ToolTip:AddLine("Garrison")
   TokenInquiry(823)
   TokenInquiry(824)
+  TokenInquiry(1101)
   TokenInquiry(910)
   TokenInquiry(999)
   TokenInquiry(1020)
diff --git a/SVUI_!Core/system/core.lua b/SVUI_!Core/system/core.lua
index 98a430e..32056c4 100644
--- a/SVUI_!Core/system/core.lua
+++ b/SVUI_!Core/system/core.lua
@@ -405,6 +405,10 @@ SV.defaults           = {
             ["breakstuff"] = true,
             ["power"] = false
         },
+        ["hearthOptions"] = {
+            ["left"] = 6948,
+            ["right"] = 110560
+        },
     },
     ["REPORT_SLOTS"] = {
         ["1"] = { "Experience Bar", "Time", "System" },
diff --git a/SVUI_!Core/system/dock.lua b/SVUI_!Core/system/dock.lua
index adb6258..bc5fa35 100644
--- a/SVUI_!Core/system/dock.lua
+++ b/SVUI_!Core/system/dock.lua
@@ -1245,13 +1245,19 @@ local DockButton_OnClick = function(self, button)
 	end
 end

-local DockButton_OnPostClick = function(self, ...)
+local DockButton_OnPostClick = function(self, button)
 	if InCombatLockdown() then
 		MOD.ErrorSound()
 		return
 	end
 	if(self.ClickTheme) then self:ClickTheme() end
-	if(self.LeftClickCallback) then self:LeftClickCallback() end
+	if(button and (button == "RightButton")) then
+		if(self.RightClickCallback) then
+			self:RightClickCallback()
+		end
+	elseif(self.LeftClickCallback) then
+		self:LeftClickCallback()
+	end
 	MOD.ButtonSound()
 end

diff --git a/SVUI_!Core/system/dropdown.lua b/SVUI_!Core/system/dropdown.lua
index 4c32adb..bc54855 100644
--- a/SVUI_!Core/system/dropdown.lua
+++ b/SVUI_!Core/system/dropdown.lua
@@ -104,7 +104,7 @@ local function GetScreenPosition(frame)
 	return result
 end

-function SV.Dropdown:Open(target, list, titleText)
+function SV.Dropdown:Open(target, list, titleText, colWidth)
 	if(InCombatLockdown() or (not list)) then return end

 	if(not self.option) then
@@ -130,13 +130,14 @@ function SV.Dropdown:Open(target, list, titleText)

 	local heightOffset = 50;
 	local heightPadded = false;
+	colWidth = colWidth or 135;

 	for i=1, #list do
 		if(not self.option[i]) then
 			-- HOLDER
 			self.option[i] = CreateFrame("Frame", nil, self);
 			self.option[i]:SetHeight(16);
-			self.option[i]:SetWidth(135);
+			self.option[i]:SetWidth(colWidth);

 			-- DIVIDER
 			self.option[i].divider = self.option[i]:CreateTexture(nil, 'BORDER');
@@ -177,6 +178,8 @@ function SV.Dropdown:Open(target, list, titleText)
 			self.option[i].slider.Text:SetJustifyH("CENTER");
 			self.option[i].slider.Low:SetJustifyH("LEFT");
 			self.option[i].slider.High:SetJustifyH("RIGHT");
+		else
+			self.option[i]:SetWidth(colWidth);
 		end

 		self.option[i]:Show();
@@ -210,11 +213,15 @@ function SV.Dropdown:Open(target, list, titleText)
 				self.option[i].header:SetText(list[i].title);
 				if(list[i].divider) then self.option[i].divider:Show(); end
 			elseif(list[i].text) then
+				local lineText = list[i].text;
+				if(list[i].icon) then
+					lineText = list[i].icon .. list[i].text
+				end
 				self.option[i].header:Hide();
 				self.option[i].slider:Hide();
 				self.option[i].button:Show();
 				self.option[i].button.target = target;
-				self.option[i].button.text:SetText(list[i].text);
+				self.option[i].button.text:SetText(lineText);
 				self.option[i].button.func = list[i].func;
 				self.option[i].button:SetScript("OnClick", DropdownButton_OnClick);
 			end
@@ -234,7 +241,7 @@ function SV.Dropdown:Open(target, list, titleText)
 	end

 	local maxHeight = (min(maxPerColumn, #list) * 16) + heightOffset;
-	local maxWidth = (135 * cols) + (10 * cols) + 10;
+	local maxWidth = (colWidth * cols) + (10 * cols) + 10;
 	local point = GetScreenPosition(target);

 	self:ClearAllPoints();
diff --git a/SVUI_!Core/system/funstuff.lua b/SVUI_!Core/system/funstuff.lua
index e7fc140..e59ab34 100644
--- a/SVUI_!Core/system/funstuff.lua
+++ b/SVUI_!Core/system/funstuff.lua
@@ -72,7 +72,7 @@ local Kill_AFK_Widget = function()
 	SV.AFK:SetScript("OnMouseDown", nil)
 	for i,name in pairs(CHAT_FRAMES) do
 		if(_G[name]) then
-			_G[name]:EnableMouse(true);
+			SetChatWindowUninteractable(i, false)
 		end
 	end
 	UIParent:Show();
diff --git a/SVUI_!Core/system/misc.lua b/SVUI_!Core/system/misc.lua
index 7d4234a..e58ec7b 100644
--- a/SVUI_!Core/system/misc.lua
+++ b/SVUI_!Core/system/misc.lua
@@ -199,7 +199,7 @@ local MaxStackTooltip = function(self)
 	local itemLink = GetMerchantItemLink(self:GetID())
 	if not itemLink then return end
 	local maxStack = select(8, GetItemInfo(itemLink))
-	if(not (maxStack > 1)) then return end
+	if((not maxStack) or (maxStack < 2)) then return end
     GameTooltip.InjectedDouble[1] = "[Alt + Click]"
     GameTooltip.InjectedDouble[2] = "Buy a full stack."
     GameTooltip.InjectedDouble[3] = 0
diff --git a/SVUI_ActionBars/SVUI_ActionBars.lua b/SVUI_ActionBars/SVUI_ActionBars.lua
index 1796580..7031189 100644
--- a/SVUI_ActionBars/SVUI_ActionBars.lua
+++ b/SVUI_ActionBars/SVUI_ActionBars.lua
@@ -27,33 +27,6 @@ local find, format, split = string.find, string.format, string.split;
 local gsub = string.gsub;
 --[[ MATH METHODS ]]--
 local ceil = math.ceil;
---BLIZZARD API
-local YES                   = _G.YES;
-local NO                    = _G.NO;
-local NONE                  = _G.NONE;
-local SetCVar               = _G.SetCVar;
-local GetCVar               = _G.GetCVar;
-local GetCVarBool           = _G.GetCVarBool;
-local C_PetBattles          = _G.C_PetBattles;
-local CreateFrame           = _G.CreateFrame;
-local InCombatLockdown      = _G.InCombatLockdown;
-local GameTooltip           = _G.GameTooltip;
-local hooksecurefunc        = _G.hooksecurefunc;
-local UnitExists            = _G.UnitExists;
-local VehicleExit           = _G.VehicleExit;
-local PetDismiss            = _G.PetDismiss;
-local GetBindingKey         = _G.GetBindingKey;
-local GetVehicleBarIndex    = _G.GetVehicleBarIndex;
-local SetDesaturation       = _G.SetDesaturation;
-local CooldownFrame_SetTimer= _G.CooldownFrame_SetTimer;
-local RegisterStateDriver 	= _G.RegisterStateDriver;
-local UnregisterStateDriver = _G.UnregisterStateDriver;
-local NUM_STANCE_SLOTS  	= _G.NUM_STANCE_SLOTS;
-local NUM_PET_ACTION_SLOTS  = _G.NUM_PET_ACTION_SLOTS;
-local SpellFlyout  			= _G.SpellFlyout;
-local GetFlyoutID  			= _G.GetFlyoutID;
-local GetNumFlyouts  		= _G.GetNumFlyouts;
-local GetFlyoutInfo  		= _G.GetFlyoutInfo;
 --[[
 ##########################################################
 GET ADDON DATA
diff --git a/SVUI_Chat/SVUI_Chat.lua b/SVUI_Chat/SVUI_Chat.lua
index eb7d0b3..04be5f3 100644
--- a/SVUI_Chat/SVUI_Chat.lua
+++ b/SVUI_Chat/SVUI_Chat.lua
@@ -1017,6 +1017,7 @@ do
 			FCF_FadeInChatFrame(chat);
 			local dockingKey = chat.Dock:GetName()
 			chat.Dock.Button:SetDocked(MOD.private.activeTabs[dockingKey])
+			SetChatWindowUninteractable(i, false)
 		end
 		refreshLocked = true
 	end
@@ -1622,7 +1623,8 @@ function MOD:Load()

 	for i,name in pairs(CHAT_FRAMES) do
 		if(_G[name]) then
-			_G[name]:SetMovable(true);
+			SetChatWindowUninteractable(i, false)
+			--_G[name]:SetMovable(true);
 			_G[name].oldAlpha = 0;
 			local key = format("SVUI_ChatFrameDock%d", i)
 			if((not self.private.activeTabs[key]) and (i < 4)) then
diff --git a/SVUI_QuestTracker/SVUI_QuestTracker.lua b/SVUI_QuestTracker/SVUI_QuestTracker.lua
index 6790590..1720abf 100644
--- a/SVUI_QuestTracker/SVUI_QuestTracker.lua
+++ b/SVUI_QuestTracker/SVUI_QuestTracker.lua
@@ -55,6 +55,7 @@ local L = SV.L
 local LSM = _G.LibStub("LibSharedMedia-3.0")
 local MOD = SV.QuestTracker;
 if(not MOD) then return end;
+MOD.DOCK_IS_FADED = false;
 --[[
 ##########################################################
 LOCALS
@@ -418,6 +419,18 @@ local function ExpandQuestTracker(location)
 	SV.Timers:ExecuteTimer(MOD.UpdateDimensions, 0.2)
 end

+local function PostFadeInCallback(location)
+	if(not location or (location ~= MOD.Docklet.Parent.Bar.Data.Location)) then return end
+	MOD.DOCK_IS_FADED = false;
+	--print(MOD.DOCK_IS_FADED)
+end
+
+local function PostFadeOutCallback(location)
+	if(not location or (location ~= MOD.Docklet.Parent.Bar.Data.Location)) then return end
+	MOD.DOCK_IS_FADED = true;
+	--print(MOD.DOCK_IS_FADED)
+end
+
 function MOD:UpdateLocals()
 	ROW_WIDTH = self.Docklet.ScrollFrame:GetWidth();
 	local baseWidth = SV.db.QuestTracker.rowHeight;
@@ -504,4 +517,6 @@ function MOD:Load()
 	self.Headers["Popups"]:Refresh()

 	SV.Events:On("DOCK_EXPANDED", ExpandQuestTracker, true);
+	SV.Events:On("DOCK_FADE_IN", PostFadeInCallback, true);
+	SV.Events:On("DOCK_FADE_OUT", PostFadeOutCallback, true);
 end
diff --git a/SVUI_QuestTracker/components/achievements.lua b/SVUI_QuestTracker/components/achievements.lua
index 774234d..aac57c0 100644
--- a/SVUI_QuestTracker/components/achievements.lua
+++ b/SVUI_QuestTracker/components/achievements.lua
@@ -64,6 +64,7 @@ SCRIPT HANDLERS
 ##########################################################
 ]]--
 local RowButton_OnEnter = function(self, ...)
+	if(MOD.DOCK_IS_FADED) then return end
 	GameTooltip:SetOwner(self, "ANCHOR_BOTTOMLEFT", 0, ROW_HEIGHT)
 	GameTooltip:ClearLines()
 	GameTooltip:AddDoubleLine("[Left-Click]", "View this in the achievements window.", 0, 1, 0, 1, 1, 1)
diff --git a/SVUI_QuestTracker/components/active.lua b/SVUI_QuestTracker/components/active.lua
index cc56602..1250a37 100644
--- a/SVUI_QuestTracker/components/active.lua
+++ b/SVUI_QuestTracker/components/active.lua
@@ -122,6 +122,7 @@ local ObjectiveProgressBar_OnEvent = function(self, event, ...)
 end

 local ActiveButton_OnEnter = function(self, ...)
+	if(MOD.DOCK_IS_FADED) then return end
 	GameTooltip:SetOwner(self, "ANCHOR_BOTTOMLEFT", 0, ROW_HEIGHT)
 	GameTooltip:ClearLines()
 	GameTooltip:AddDoubleLine("[Left-Click]", "View the log entry for this quest.", 0, 1, 0, 1, 1, 1)
diff --git a/SVUI_QuestTracker/components/quests.lua b/SVUI_QuestTracker/components/quests.lua
index 63a19ae..edcbb9a 100644
--- a/SVUI_QuestTracker/components/quests.lua
+++ b/SVUI_QuestTracker/components/quests.lua
@@ -117,6 +117,7 @@ do
     end

     local Button_OnEnter = function(self)
+    	if(MOD.DOCK_IS_FADED) then return end
         if(self.itemID) then
             GameTooltip:SetOwner(self, 'ANCHOR_LEFT')
             GameTooltip:SetHyperlink(self.itemLink)
@@ -323,7 +324,7 @@ local function HideItemBarButtons()
 		local button = ItemBar.Buttons[i];
 		button:FadeOut(0.1, 1, 0, true);
 	end
-	ItemBar:FadeOut(0.1, 1, 0, true)
+	ItemBar:FadeOut(0.1, 1, 0, true);
 end

 local function ShowItemBarButtons()
@@ -614,6 +615,7 @@ SCRIPT HANDLERS
 ##########################################################
 ]]--
 local BadgeButton_OnEnter = function(self, ...)
+	if(MOD.DOCK_IS_FADED) then return end
 	GameTooltip:SetOwner(self, "ANCHOR_BOTTOMLEFT", 0, ROW_HEIGHT)
 	GameTooltip:ClearLines()
 	GameTooltip:AddLine("Click to track this quest.")
@@ -621,6 +623,7 @@ local BadgeButton_OnEnter = function(self, ...)
 end

 local RowButton_OnEnter = function(self, ...)
+	if(MOD.DOCK_IS_FADED) then return end
 	GameTooltip:SetOwner(self, "ANCHOR_BOTTOMLEFT", 0, ROW_HEIGHT)
 	GameTooltip:ClearLines()
 	GameTooltip:AddDoubleLine("[Left-Click]", "View the log entry for this quest.", 0, 1, 0, 1, 1, 1)
@@ -1021,7 +1024,6 @@ local AddOneQuest = function(self, questID)
 end

 local ResetQuestBlock = function(self)
-	if(not self:IsVisible()) then return end
 	for x = 1, #self.Rows do
 		local row = self.Rows[x]
 		if(row) then
@@ -1063,7 +1065,6 @@ CORE FUNCTIONS
 ##########################################################
 ]]--
 function MOD:UpdateObjectives(event, ...)
-	if(not self.Headers["Quests"]:IsVisible()) then return end
 	if(event == "ZONE_CHANGED_NEW_AREA") then
 		if(not WorldMapFrame:IsShown() and GetCVarBool("questPOI")) then
 			SetMapToCurrentZone();
diff --git a/SVUI_UnitFrames/frames.lua b/SVUI_UnitFrames/frames.lua
index 68118a9..02c8a7a 100644
--- a/SVUI_UnitFrames/frames.lua
+++ b/SVUI_UnitFrames/frames.lua
@@ -711,7 +711,7 @@ CONSTRUCTORS["boss"] = function(self, unit)
     self.Afflicted = MOD:CreateAfflicted(self)
     self.Castbar = MOD:CreateCastbar(self, true, nil, true, nil, true)
     self.RaidIcon = MOD:CreateRaidIcon(self)
-    self.AltPowerBar = MOD:CreateAltPowerBar(self)
+    --self.AltPowerBar = MOD:CreateAltPowerBar(self)

     self.Restrict = RestrictElement
     self.Allow = AllowElement