Quantcast

Added "is_linked" parameter to addon:DisplayFrame() - saves the linked state to the MainPanel so calls to UpdateFilters() will show correct results.

James D. Callahan III [04-15-10 - 06:41]
Added "is_linked" parameter to addon:DisplayFrame() - saves the linked state to the MainPanel so calls to UpdateFilters() will show correct results.
Filename
ARL.lua
Frame.lua
diff --git a/ARL.lua b/ARL.lua
index 0142d58..376e46d 100644
--- a/ARL.lua
+++ b/ARL.lua
@@ -1893,7 +1893,7 @@ do
 		if textdump then
 			self:DisplayTextDump(recipe_list, Player.current_prof)
 		else
-			self:DisplayFrame()
+			self:DisplayFrame(is_linked)
 		end
 	end
 end
diff --git a/Frame.lua b/Frame.lua
index d54efcc..f2176e9 100644
--- a/Frame.lua
+++ b/Frame.lua
@@ -4362,11 +4362,13 @@ end
 -------------------------------------------------------------------------------
 -- Displays the main recipe frame.
 -------------------------------------------------------------------------------
-function addon:DisplayFrame()
+function addon:DisplayFrame(is_linked)
 	MainPanel:SetPosition()
 	MainPanel:SetProfession()
 	MainPanel:SetScale(addon.db.profile.frameopts.uiscale)

+	MainPanel.is_linked = is_linked
+
 	ARL_DD_Sort.initialize = ARL_DD_Sort_Initialize				-- Initialize dropdown

 	local editbox = SearchBox
@@ -4389,7 +4391,7 @@ end
 --- Upvalued at the top of the file.
 --------------------------------------------------------------------------------
 function ReDisplay()
-	addon:UpdateFilters()
+	addon:UpdateFilters(MainPanel.is_linked)
 	Player:MarkExclusions()

 	ListFrame:Update(false, false)