Mercurial > wow > itemauditor
diff Modules/Debug.lua @ 16:56de19d9bd8d
Cleaned up the messages. You can turn the notifications of price changes off and those messages will only show gold or silver if they are more than 0. I have also removed the dependency on AceConsole because it doesn't allow changing the color of the addon name when I print messages.
author | Asa Ayers <Asa.Ayers@Gmail.com> |
---|---|
date | Sat, 03 Jul 2010 10:05:53 -0700 |
parents | bbba2fae0f69 |
children | 66b7c3f5937e |
line wrap: on
line diff
--- a/Modules/Debug.lua Sat Jul 03 07:40:01 2010 -0700 +++ b/Modules/Debug.lua Sat Jul 03 10:05:53 2010 -0700 @@ -5,11 +5,24 @@ function addon:Debug(msg) - if self.db.char.debug then + if self.db.profile.messages.debug then self:Print(msg) end end +function addon:GetDebug(info) + return self.db.profile.messages.debug +end + +function addon:SetDebug(info, input) + self.db.profile.messages.debug = input + local value = "off" + if input then + value = "on" + end + self:Print("Debugging is now: " .. value) +end + local function DebugEventRegistration() addon.OriginalRegisterEvent = addon.RegisterEvent addon.OriginalUnregisterEvent = addon.UnregisterEvent