diff gui.lua @ 54:6d5fcbdc0590

DoTimerEditBoxDropDown widget to ver 5, warn (once) about missing item cache entries in the filter list dropdown.
author Farmbuyer of US-Kilrogg <farmbuyer@gmail.com>
date Sat, 07 Apr 2012 04:59:27 +0000
parents 7af58a7dce7d
children ac57a4342812
line wrap: on
line diff
--- a/gui.lua	Fri Apr 06 18:23:22 2012 +0000
+++ b/gui.lua	Sat Apr 07 04:59:27 2012 +0000
@@ -1744,10 +1744,13 @@
 		grp:AddChild(w)
 		do
 			local list = {}
+			local cache_warn, cache_warned = false, false
 			for id in pairs(OuroLootSV_opts.itemfilter) do
 				local iname, _, iquality = GetItemInfo(id)
 				if iname then
 					list[id] = ITEM_QUALITY_COLORS[iquality].hex .. iname .. "|r"
+				else
+					cache_warn = true
 				end
 			end
 			w = GUI:Create("EditBoxDropDown")
@@ -1771,6 +1774,12 @@
 				--addon:Print("No longer filtering out", ilink)
 				addon:Print("No longer filtering out", val_name)
 			end)
+			w:SetCallback("OnDropdownShown", function()
+				if cache_warn and not cache_warned then
+					cache_warned = true
+					addon:Print("At least one of the items in the filter list was not in your game client's cache.  This is okay.  Just wait a few seconds, display some other Ouro Loot tab, and then display Options again.")
+				end
+			end)
 			grp:AddChild(w)
 		end