For recipe entries, changed "Search" to "is_relevant".
James D. Callahan III [03-09-10 - 12:58]
For recipe entries, changed "Search" to "is_relevant".
diff --git a/ARL.lua b/ARL.lua
index b278c73..c75d7a2 100644
--- a/ARL.lua
+++ b/ARL.lua
@@ -871,8 +871,6 @@ function addon:addTradeSkill(RecipeDB, spell_id, skill_level, item_id, quality,
["profession"] = profession_id,
["spell_link"] = GetSpellLink(spell_id),
["name"] = recipe_name,
- ["is_visible"] = true, -- Set to be displayed until the filtering occurs
- ["Search"] = true, -- Set to be showing in the search results
["Flags"] = {}, -- Create the flag space in the RecipeDB
["Acquire"] = {}, -- Create the Acquire space in the RecipeDB
["specialty"] = specialty, -- Assumption: there will only be 1 speciality for a trade skill
@@ -881,6 +879,8 @@ function addon:addTradeSkill(RecipeDB, spell_id, skill_level, item_id, quality,
["medium_level"] = medium_level or skill_level + 10,
["easy_level"] = easy_level or skill_level + 15,
["trivial_level"] = trivial_level or skill_level + 20,
+ ["is_visible"] = true, -- Set to be displayed until the filtering occurs
+ ["is_relevant"] = true, -- Set to be showing in the search results
}
if not recipe.name then
diff --git a/Frame.lua b/Frame.lua
index 93b8961..66d051f 100644
--- a/Frame.lua
+++ b/Frame.lua
@@ -2140,7 +2140,7 @@ do
local recipe_index = sorted_recipes[i]
local recipe_entry = recipe_list[recipe_index]
- if recipe_entry.is_visible and recipe_entry["Search"] then
+ if recipe_entry.is_visible and recipe_entry.is_relevant then
-- Determine if the player has an appropiate level in any applicable faction
-- to learn the recipe.
local acquire_info = recipe_entry["Acquire"]
@@ -3027,7 +3027,7 @@ do
for i = 1, #sorted_recipes do
local recipe_entry = recipe_list[sorted_recipes[i]]
- if recipe_entry.is_visible and recipe_entry["Search"] then
+ if recipe_entry.is_visible and recipe_entry.is_relevant then
-- loop through acquire methods, display each
for index, acquire in pairs(recipe_entry["Acquire"]) do
if CheckMapDisplay(acquire, recipe_entry["Flags"]) then
@@ -3446,13 +3446,13 @@ function addon:InitializeFrame()
for index in pairs(recipe_list) do
local entry = recipe_list[index]
- entry["Search"] = false
+ entry.is_relevant = false
for field in pairs(search_params) do
local str = entry[field] and tostring(entry[field]):lower() or nil
if str and str:find(pattern) then
- entry["Search"] = true
+ entry.is_relevant = true
break
end
end
@@ -3493,7 +3493,7 @@ function addon:InitializeFrame()
-- Reset the search flags
for index in pairs(recipe_list) do
- recipe_list[index]["Search"] = true
+ recipe_list[index].is_relevant = true
end
ARL_SearchText:SetText(L["SEARCH_BOX_DESC"])