view ItemCountAddons/Altoholic.lua @ 54:06fee4208bf2

Altoholic should now properly show an on select message when chosen. Selecting DataStore as item count addons should no longer break. The local item count displayed in the summary is now actually local rather than global.
author Zerotorescue
date Mon, 20 Dec 2010 14:30:31 +0100
parents 9607b3251655
children
line wrap: on
line source
do
	
	local function GetTotalCount(itemId)
		return Altoholic:GetItemCount(itemId) or -1;
	end
	
	local function IsEnabled()
		return (Altoholic and Altoholic.GetItemCount);
	end
	
	local function OnSelect()
		local addonName = "|r|cfffed000Altoholic|r|cffff6600";
		
		print("|cffff6600Note: " .. addonName .. " can not provide local item data.|r");
	end
	
	IMRegisterItemCountAddon("Altoholic", GetTotalCount, nil, IsEnabled, OnSelect);
	
end