From 42531ad2f4f89c38af538a91de03bffcd0be6a69 Mon Sep 17 00:00:00 2001 From: "James D. Callahan III" Date: Thu, 25 Mar 2010 13:12:23 -0400 Subject: [PATCH] In MainPanel.scroll_frame:Update(): For Location entries, started work on displaying only the acquire types relevant to that location - at the moment it's using ExpandTrainerData() and ExpandVendorData(). --- Frame.lua | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Frame.lua b/Frame.lua index f6d15b9..6a5577c 100644 --- a/Frame.lua +++ b/Frame.lua @@ -3282,7 +3282,7 @@ do elseif list_entry.type == "subheader" then for acquire_type, acquire_data in pairs(private.recipe_list[list_entry.recipe_id].acquire_data) do if acquire_type == acquire_id then - entry_index = self:ExpandAcquireData(entry_index, "subentry", acquire_type, acquire_data, list_entry.recipe_id, true) + entry_index = self:ExpandAcquireData(entry_index, "subentry", acquire_type, acquire_data, list_entry.recipe_id, false, true) end end end @@ -3322,7 +3322,14 @@ do local recipe_entry = private.recipe_list[list_entry.recipe_id] for acquire_type, acquire_data in pairs(recipe_entry.acquire_data) do - entry_index = self:ExpandAcquireData(entry_index, "subentry", acquire_type, acquire_data, list_entry.recipe_id, false) + for id_num in pairs(acquire_data) do + + if acquire_type == A.TRAINER and private.trainer_list[id_num].location == location_id then + entry_index = ExpandTrainerData(entry_index, "subentry", id_num, list_entry.recipe_id, true) + elseif acquire_type == A.VENDOR and private.vendor_list[id_num].location == location_id then + entry_index = ExpandVendorData(entry_index, "subentry", id_num, list_entry.recipe_id, true) + end + end end end return entry_index -- 1.7.9.5