changeset 68:eadff31e61e8

Localization of all files. Testing packager settings (especially automatic locale exports), localization is not yet finished.
author Zerotorescue
date Wed, 15 Sep 2010 13:10:56 +0200
parents 4166a335ca81
children 21b5ecd7d018
files Core.lua Localization/enUS.lua MailOpener.toc Modules/BeanCounterSupport.lua Modules/Collected.lua Modules/Config.lua Modules/FailSafe.lua Modules/OpenAll.lua
diffstat 8 files changed, 464 insertions(+), 343 deletions(-) [+]
line wrap: on
line diff
--- a/Core.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Core.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,5 +1,6 @@
 -- You can access this addon's object through: LibStub("AceAddon-3.0"):GetAddon("MailOpener")
 local MailOpener = LibStub("AceAddon-3.0"):NewAddon("MailOpener", "AceEvent-3.0", "AceTimer-3.0");
+local L = LibStub("AceLocale-3.0"):GetLocale("MailOpener");
 
 -- You can check if MailOpener is busy with the global MailAddonBusy (if not MailAddonBusy then ...do something... end)
 -- MailAddonBusy will be nil when nothing is happening or filled with the addon name when MO is working
@@ -99,9 +100,9 @@
 	for name, module in self:IterateModules() do
 		if self.db.profile.modules[name] ~= nil then
 			if self.db.profile.modules[name] then
-				self:Debug("|cff00ff00Enabling|r module: " .. name);
+				self:Debug(("|cff00ff00Enabling|r module: "):format(name));
 			else
-				self:Debug("|cffff0000Disabling|r module: " .. name);
+				self:Debug(("|cffff0000Disabling|r module: "):format(name));
 			end
 			
 			module:SetEnabledState(self.db.profile.modules[name]);
@@ -175,7 +176,7 @@
 			-- Shift key = toggle addon on or off, since addon is already on there's only one option
 			
 			if not MailOpener:IsEnabled() then
-				print("|cff15ff00Mail Opener|r: Shift key was held down, so |cff00ff00enabling|r the entire addon as well as automatic opening of mail.");
+				self:Print(L["Shift key was held down, so |cff00ff00enabling|r the entire addon as well as automatic opening of mail."]);
 				
 				MailOpener:Enable();
 				
@@ -184,7 +185,7 @@
 				
 				self:SetChecked(true);
 			else
-				print("|cff15ff00Mail Opener|r: Shift key was held down, so |cffff0000disabling|r the entire addon.");
+				self:Print(L["Shift key was held down, so |cffff0000disabling|r the entire addon."]);
 				
 				MailOpener:Disable();
 				
@@ -194,19 +195,19 @@
 			-- Normal click
 			
 			if self:GetChecked() then
-				print("|cff15ff00Mail Opener|r: |cff00ff00Enabling|r automatic opening of mail.");
+				self:Print(L["|cff00ff00Enabling|r automatic opening of mail."]);
 				
 				AutoOpenMail = true;
 				MailOpener:ScheduleOpen(false);
 			else
-				print("|cff15ff00Mail Opener|r: |cffff0000Disabling|r automatic opening of mail.");
+				self:Print(L["|cffff0000Disabling|r automatic opening of mail."]);
 				
 				AutoOpenMail = false;
 			end
 		end
 	end);
-	check.tooltipTitle = "Mail Opener status";
-	check.tooltip = "Toggle automatic mail opening |cff00ff00on|r or |cffff0000off|r (you can also enforce this by holding shift when opening the mailbox).\n\nYou can toggle this addon |cff00ff00on|r or |cffff0000off|r by |cfffed000shift-clicking|r this checkbox.";
+	check.tooltipTitle = L["Mail Opener status"];
+	check.tooltip = L["Toggle automatic mail opening |cff00ff00on|r or |cffff0000off|r (you can also enforce this by holding shift when opening the mailbox).\n\nYou can toggle this addon |cff00ff00on|r or |cffff0000off|r by |cfffed000shift-clicking|r this checkbox."];
 	check:SetScript("OnEnter", function(self)
 		if MailOpener.db.profile.general.showHelpTooltips then
 			GameTooltip:SetOwner(self, "ANCHOR_BOTTOM")
@@ -226,7 +227,7 @@
 	
 	-- Get reference to the text field
 	local checkboxText = _G[check:GetName() .. "Text"];
-	checkboxText:SetText("Mail Opener");
+	checkboxText:SetText(L["Mail Opener"]);
 	
 	self.cbOpenAll = check;
 	
@@ -237,7 +238,7 @@
 	
 	-- Make the config button
 	local button = CreateFrame("Button", "btnMailOpenerConfig", MailFrame, "UIPanelButtonTemplate")
-	button:SetText("Config")
+	button:SetText(L["Config"])
 	button:SetHeight(23)
 	button:SetWidth(55)
 	button:SetPoint("TOPRIGHT", MailFrame, "TOPRIGHT", -55, -13);
@@ -250,8 +251,8 @@
 		--BETA:	MailOpener:ShowBetaPopup();
 		--BETA:end
 	end);
-	button.tooltipTitle = "Mail Opener Config";
-	button.tooltip = "Click to open the configuration window for Mail Opener.";
+	button.tooltipTitle = L["Mail Opener Config"];
+	button.tooltip = L["Click to open the configuration window for Mail Opener."];
 	button:SetScript("OnEnter", function(self)
 		if MailOpener.db.profile.general.showHelpTooltips then
 			GameTooltip:SetOwner(self, "ANCHOR_BOTTOM")
@@ -363,21 +364,21 @@
 	
 	if self.db.profile.uses == 0 and MailOpener.db.profile.general.defaultStatus ~= "_enabled" then
 		StaticPopupDialogs["MailOpenerFirstUseConfirmBox"] = {
-			text = "You are using |cff15ff00Mail Opener|r for the first time. Do you wish to always |cf00ff000enable|r |cfffed000automatic mail opening when you open the mailbox|r?\n\nYou can always change the standard behaviour in the General options.",
-			button1 = "Yes",
-			button2 = "No",
+			text = L["You are using |cff15ff00Mail Opener|r for the first time. Do you wish to always |cf00ff000enable|r |cfffed000automatic mail opening when you open the mailbox|r?\n\nYou can always change the standard behavior in the General options."],
+			button1 = L["Yes"],
+			button2 = L["No"],
 			OnAccept = function()
 				MailOpener.db.profile.general.defaultStatus = "_enabled";
-				print("|cff15ff00Mail Opener|r: You can always change the default status in the General config (|cff00ffff/mo c|r).");
+				self:Print(L["You can always change the default status in the General config (|cff00ffff/mo c|r)."]);
 				
-				print("|cff15ff00Mail Opener|r: |cff00ff00Enabling|r automatic opening of mail.");
+				self:Print(L["|cff00ff00Enabling|r automatic opening of mail."]);
 				MailOpener.cbOpenAll:SetChecked(true);
 				
 				AutoOpenMail = true;
 				MailOpener:ScheduleOpen(false);
 			end,
 			OnCancel = function (_,reason)
-				print("|cff15ff00Mail Opener|r: You can always change the default status in the General config (|cff00ffff/mo c|r).");
+				self:Print(L["You can always change the default status in the General config (|cff00ffff/mo c|r)."]);
 			end,
 			timeout = 0,
 			whileDead = 1,
@@ -406,7 +407,7 @@
 	end
 	
 	if IsShiftKeyDown() then
-		print("|cff15ff00Mail Opener|r: |cffff0000Disabling|r automatic opening of mail, shift key was down when opening the mailbox.");
+		self:Print(L["|cffff0000Disabling|r automatic opening of mail, shift key was down when opening the mailbox."]);
 		
 		AutoOpenMail = false;
 		self.cbOpenAll:SetChecked(false);
@@ -429,15 +430,6 @@
 		end
 	end
 	
-	if self.db.profile.notifications.welcome then
-		-- Welcome notification
-		local _, c = UnitClass("player");
-		c = RAID_CLASS_COLORS[c];
-		c = string.format("|cff%02x%02x%02x", c.r * 255 + 0.5, c.g * 255 + 0.5, c.b * 255 + 0.5);
-	
-		print("|cff15ff00Mail Opener|r: Welcome back "..c..UnitName("player").."|r. Requesting new mail from the local Postal Service, your mail will automatically be opened when it becomes available.");
-	end
-	
 	mailboxEmptySoundPlayed = nil;
 	mailboxEmptySoundPlayedThisVisit = nil;
 	
@@ -664,10 +656,6 @@
 
 -- Stop checking for new mail and unregister the events we needed
 function MailOpener:Stop()
-	if self.db.profile.notifications.bye then
-		print("|cff15ff00Mail Opener|r: Have a nice day. :)");
-	end
-	
 	if MailAddonBusy == self:GetName() then
 		MailAddonBusy = nil;
 	end
@@ -707,6 +695,10 @@
 	end
 end
 
+function MailOpener:Print(text)
+	print(L["|cff15ff00Mail Opener|r: %s"]:format(text));
+end
+
 -- Enable our config module if it's disabled and make a reference to it
 function MailOpener:EnableConfigModule()
 	if not MailOpenerConfig then
@@ -758,7 +750,7 @@
 
 -- General copy window for multiple things (clickable URLs, the time remaining, and such)
 StaticPopupDialogs["MailOpenerCopyWindow"] = {
-	text = "Please CTRL-C to copy.",
+	text = L["Press CTRL-C to copy."],
 	button2 = CLOSE,
 	hasEditBox = 1,
 	hasWideEditBox = 1,
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Localization/enUS.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -0,0 +1,144 @@
+-- We don't want to bother the user with a missing locale, but we do want to bother ourselves
+local silent = true;
+--@debug@
+silent = false;
+--@end-debug@
+
+silent = false;
+
+local AceLocale = LibStub:GetLibrary("AceLocale-3.0");
+local L = AceLocale:NewLocale("MailOpener", "enUS", true, silent);
+if not L then return; end
+
+--@localization(locale="enUS", format="lua_additive_table", same-key-is-true=true)@
+
+--@debug@
+
+-- Core
+L["|cff00ff00Enabling|r automatic opening of mail."] = "|cff00ff00Enabling|r automatic opening of mail." -- Needs review
+L["|cff15ff00Mail Opener|r: %s"] = "|cff15ff00Mail Opener|r: %s"
+L["|cffff0000Disabling|r automatic opening of mail."] = "|cffff0000Disabling|r automatic opening of mail." -- Needs review
+L["|cffff0000Disabling|r automatic opening of mail, shift key was down when opening the mailbox."] = "|cffff0000Disabling|r automatic opening of mail, shift key was down when opening the mailbox." -- Needs review
+L["Click here to completely toggle this module on or off."] = "Click here to completely toggle this module on or off." -- Needs review
+L["Click to open the configuration window for Mail Opener."] = "Click to open the configuration window for Mail Opener." -- Needs review
+L["Config"] = "Config"
+L["Disable Module"] = "Disable Module"
+L["Enable Module"] = "Enable Module"
+L["General"] = "General"
+L["Mail Opener"] = "Mail Opener" -- Needs review
+L["Mail Opener Config"] = "Mail Opener Config" -- Needs review
+L["Mail Opener status"] = "Mail Opener status" -- Needs review
+L["Press CTRL-C to copy."] = "Press CTRL-C to copy." -- Needs review
+L["Shift key was held down, so |cff00ff00enabling|r the entire addon as well as automatic opening of mail."] = "Shift key was held down, so |cff00ff00enabling|r the entire addon as well as automatic opening of mail." -- Needs review
+L["Shift key was held down, so |cffff0000disabling|r the entire addon."] = "Shift key was held down, so |cffff0000disabling|r the entire addon." -- Needs review
+L["Status: |cff00ff00Enabled|r"] = "Status: |cff00ff00Enabled|r"
+L["Status: |cffff0000Disabled|r"] = "Status: |cffff0000Disabled|r" -- Needs review
+L[ [=[Toggle automatic mail opening |cff00ff00on|r or |cffff0000off|r (you can also enforce this by holding shift when opening the mailbox).
+
+You can toggle this addon |cff00ff00on|r or |cffff0000off|r by |cfffed000shift-clicking|r this checkbox.]=] ] = [=[Toggle automatic mail opening |cff00ff00on|r or |cffff0000off|r (you can also enforce this by holding shift when opening the mailbox).
+
+You can toggle this addon |cff00ff00on|r or |cffff0000off|r by |cfffed000shift-clicking|r this checkbox.]=] -- Needs review
+L["With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set."] = "With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set." -- Needs review
+L[ [=[You are using |cff15ff00Mail Opener|r for the first time. Do you wish to always |cf00ff000enable|r |cfffed000automatic mail opening when you open the mailbox|r?
+
+You can always change the standard behavior in the General options.]=] ] = [=[You are using |cff15ff00Mail Opener|r for the first time. Do you wish to always |cf00ff000enable|r |cfffed000automatic mail opening when you open the mailbox|r?
+
+You can always change the standard behavior in the General options.]=] -- Needs review
+L["You can always change the default status in the General config (|cff00ffff/mo c|r)."] = "You can always change the default status in the General config (|cff00ffff/mo c|r)." -- Needs review
+
+-- OpenAll
+L["Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r, regardless of the above filters."] = "Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r, regardless of the above filters." -- Needs review
+L["Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r with attachments, temporarily overriding all filters."] = "Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r with attachments, temporarily overriding all filters." -- Needs review
+L["Auction canceled"] = "Auction canceled" -- Needs review
+L["Auction expired"] = "Auction expired" -- Needs review
+L["Auction House Mail"] = "Auction House Mail" -- Needs review
+L["Auction outbid"] = "Auction outbid" -- Needs review
+L["Auction successful"] = "Auction successful" -- Needs review
+L["auction won"] = "auction won" -- Needs review
+L["Auction won"] = "Auction won" -- Needs review
+L["Automatically loot all auction canceled mail from the auction house."] = "Automatically loot all auction canceled mail from the auction house." -- Needs review
+L["Automatically loot all auction expired mail from the auction house."] = "Automatically loot all auction expired mail from the auction house." -- Needs review
+L["Automatically loot all auction outbid mail from the auction house."] = "Automatically loot all auction outbid mail from the auction house." -- Needs review
+L["Automatically loot all auction successful mail from the auction house."] = "Automatically loot all auction successful mail from the auction house." -- Needs review
+L["Automatically loot all auction won mail from the auction house."] = "Automatically loot all auction won mail from the auction house." -- Needs review
+L["Automatically loot all normal mail containing attachments (CoDs and Blizzard mail will be skipped)."] = "Automatically loot all normal mail containing attachments (CoDs and Blizzard mail will be skipped)." -- Needs review
+L["Automatically loot all normal mail containing gold (CoDs and Blizzard mail will be skipped)."] = "Automatically loot all normal mail containing gold (CoDs and Blizzard mail will be skipped)." -- Needs review
+L["Blizzard mail"] = "Blizzard mail"
+L["canceled auction"] = "canceled auction" -- Needs review
+L["|cffff0000There is currently no mail available.|r"] = "|cffff0000There is currently no mail available.|r" -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining - everything will be opened soon..."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining - everything will be opened soon..." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining, next refresh in |cffffffff%d|r seconds."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining, next refresh in |cffffffff%d|r seconds." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes and |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes and |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes (next refresh in |cffffffff%d|r seconds)."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes (next refresh in |cffffffff%d|r seconds)." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for something from the current batch to be opened..."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for something from the current batch to be opened..." -- Needs review
+L["|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for the next mailbox refresh..."] = "|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for the next mailbox refresh..." -- Needs review
+L["Change open all settings."] = "Change open all settings." -- Needs review
+L[ [=[Change the amount of space to reserve for other things when opening mail. If this option is set higher than 0, mail with a higher amount of attachments than available space will be skipped completely.
+
+E.g. If this is set to 1 and you have a total of 12 slots left then any mail with 12 attachments will be skipped while one with 11 attachments would be opened.]=] ] = [=[Change the amount of space to reserve for other things when opening mail. If this option is set higher than 0, mail with a higher amount of attachments than available space will be skipped completely.
+
+E.g. If this is set to 1 and you have a total of 12 slots left then any mail with 12 attachments will be skipped while one with 11 attachments would be opened.]=] -- Needs review
+L[ [=[Change the delay before Mail Opener tries opening mail after opening the mailbox or new mail has been received from the server.
+
+The default value is 0.5 seconds.]=] ] = [=[Change the delay before Mail Opener tries opening mail after opening the mailbox or new mail has been received from the server.
+
+The default value is 0.5 seconds.]=] -- Needs review
+L[ [=[Change the interval at which Mail Opener tries to continue opening mail after opening the mailbox. Please note that this setting does not reduce the game's normal 60 seconds wait time for mail.
+
+The default value is 5 seconds.]=] ] = [=[Change the interval at which Mail Opener tries to continue opening mail after opening the mailbox. Please note that this setting does not reduce the game's normal 60 seconds wait time for mail.
+
+The default value is 5 seconds.]=] -- Needs review
+L["Change the mail opening speed (in microseconds) for each mail. Lower may not always be faster."] = "Change the mail opening speed (in microseconds) for each mail. Lower may not always be faster." -- Needs review
+L["Change the speed at which mail is opened. You should set the opening speed to the lowest latency you have in a city or experiment with setting it to the minimum."] = "Change the speed at which mail is opened. You should set the opening speed to the lowest latency you have in a city or experiment with setting it to the minimum." -- Needs review
+L["C.O.D."] = "C.O.D." -- Needs review
+L["Continued Mail Opening Interval"] = "Continued Mail Opening Interval" -- Needs review
+L["Continue opening mail"] = "Continue opening mail" -- Needs review
+L["Continue opening mail at the interval set below, even if the mailbox wasn't refreshed recently."] = "Continue opening mail at the interval set below, even if the mailbox wasn't refreshed recently." -- Needs review
+L["expired auction"] = "expired auction" -- Needs review
+L["Filters"] = "Filters" -- Needs review
+L["Finished opening the current batch."] = "Finished opening the current batch." -- Needs review
+L[ [=[Hold |cfffed000shift|r while clicking this button to temporarily override your filters and loot every single mail containing attachments and/or gold.
+
+|cfffed000Right|r click this button to quickly adjust mail opening filters for this profile.]=] ] = [=[Hold |cfffed000shift|r while clicking this button to temporarily override your filters and loot every single mail containing attachments and/or gold.
+
+|cfffed000Right|r click this button to quickly adjust mail opening filters for this profile.]=] -- Needs review
+L["Initial Mail Opening Delay"] = "Initial Mail Opening Delay" -- Needs review
+L["inventory is full"] = "inventory is full" -- Needs review
+L["Keep free space"] = "Keep free space" -- Needs review
+L["Keep Free Space"] = "Keep Free Space" -- Needs review
+L["keep free space limit"] = "keep free space limit" -- Needs review
+L["Mail Opener will |cff00ff00continue|r to attempt to open the remaining mail every |cfffed000%d seconds|r."] = "Mail Opener will |cff00ff00continue|r to attempt to open the remaining mail every |cfffed000%d seconds|r." -- Needs review
+L["Mail Opener will |cffff0000not|r continue to attempt to open the remaining mail and will only start opening when new mail has just been received from the server."] = "Mail Opener will |cffff0000not|r continue to attempt to open the remaining mail and will only start opening when new mail has just been received from the server." -- Needs review
+L["normal mail with attachments"] = "normal mail with attachments" -- Needs review
+L["Normal mail with |cfffed000attachments|r"] = "Normal mail with |cfffed000attachments|r" -- Needs review
+L["Normal mail with |cfffed000gold|r"] = "Normal mail with |cfffed000gold|r" -- Needs review
+L["normal mail with gold"] = "normal mail with gold" -- Needs review
+L["Open all"] = "Open all" -- Needs review
+L["Open All"] = "Open All" -- Needs review
+L["Open all |cfffed000auction canceled|r mail"] = "Open all |cfffed000auction canceled|r mail" -- Needs review
+L["Open all |cfffed000auction expired|r mail"] = "Open all |cfffed000auction expired|r mail" -- Needs review
+L["Open all |cfffed000auction successful|r mail"] = "Open all |cfffed000auction successful|r mail" -- Needs review
+L["Open all |cfffed000auction won|r mail"] = "Open all |cfffed000auction won|r mail" -- Needs review
+L["Opening..."] = "Opening..." -- Needs review
+L["Opening Interval"] = "Opening Interval" -- Needs review
+L["Opening Speed"] = "Opening Speed" -- Needs review
+L["Open single mail interval"] = "Open single mail interval" -- Needs review
+L["Other mail with attachments"] = "Other mail with attachments" -- Needs review
+L["Other mail with gold"] = "Other mail with gold" -- Needs review
+L["outbid on auction"] = "outbid on auction" -- Needs review
+L["Processing %d: %s"] = "Processing %d: %s" -- Needs review
+L["Processing %d: %s (%s)"] = "Processing %d: %s (%s)" -- Needs review
+L["Remaining Mail"] = "Remaining Mail" -- Needs review
+L["Shift key was held while pressing the open all button. Temporarily overriding filters; going to open every mail with attachments."] = "Shift key was held while pressing the open all button. Temporarily overriding filters; going to open every mail with attachments." -- Needs review
+L["Skipping %d: %s"] = "Skipping %d: %s" -- Needs review
+L["Skipping %d: %s (%s)"] = "Skipping %d: %s (%s)" -- Needs review
+L["successful auction"] = "successful auction" -- Needs review
+L["The actual mail opening initiated by the core."] = "The actual mail opening initiated by the core." -- Needs review
+L["The default behavior for opening mail is to only do so right after new mail was received from the server. If you close the mailbox or your inventory is full before everything is opened you will have to click the open all button manually or wait for a next mailbox refresh."] = "The default behavior for opening mail is to only do so right after new mail was received from the server. If you close the mailbox or your inventory is full before everything is opened you will have to click the open all button manually or wait for a next mailbox refresh." -- Needs review
+L["The first batch after each server refresh will be opened after waiting |cfffed000%d seconds|r."] = "The first batch after each server refresh will be opened after waiting |cfffed000%d seconds|r." -- Needs review
+L["Toggle filters for %s profile."] = "Toggle filters for %s profile." -- Needs review
+L["Toggle which mail the opener should autoloot."] = "Toggle which mail the opener should autoloot." -- Needs review
+L["You can set an amount of bag space you wish to reserve when opening mail. Mail with a higher amount of attachments than available space will be skipped completely with this option set above 0."] = "You can set an amount of bag space you wish to reserve when opening mail. Mail with a higher amount of attachments than available space will be skipped completely with this option set above 0." -- Needs review
+
+--@end-debug@
\ No newline at end of file
--- a/MailOpener.toc	Tue Sep 14 11:17:38 2010 +0200
+++ b/MailOpener.toc	Wed Sep 15 13:10:56 2010 +0200
@@ -11,6 +11,8 @@
 
 embeds.xml
 
+Localization\enUS.lua
+
 Core.lua
 
 Modules\BeanCounterSupport.lua
--- a/Modules/BeanCounterSupport.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Modules/BeanCounterSupport.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,7 +1,7 @@
 local MailOpener = LibStub("AceAddon-3.0"):GetAddon("MailOpener");
 local mod = MailOpener:NewModule("BeanCounterSupport", "AceEvent-3.0", "AceHook-3.0");
 
-mod.moduleDescription = "Prevents mail opening while BeanCounter is still scanning. Does nothing when BeanCounter is disabled.";
+mod.moduleDescription = L["Prevents mail opening while BeanCounter is still scanning. Does nothing when BeanCounter is disabled."];
 mod.moduleRequired = false;
 
 local MailAddonName = "BeanCounter"; -- what to fill the global MailAddonBusy with
@@ -104,31 +104,31 @@
 	local configGroup = {
 		order = 0,
 		type = "modulesSubGroup",
-		name = "BeanCounter Support",
-		desc = "Change settings for the BeanCounter Support module.",
+		name = L["BeanCounter Support"],
+		desc = L["Change settings for the BeanCounter Support module."],
 		args = {
 			General = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "General",
+				name = L["General"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
 						name = function()
-							local descText = "With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set.\n\n";
+							local descText = L["With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set."] .. "\n\n";
 							
 							-- Behavior info
-							descText = descText .. "|cfffed000Please note this module will only be enabled when the addon \"BeanCounter\" is enabled. This module will be disabled when BeanCounter could not be found and enabled when it can unless you manually disabled this module.|r\n\n";
+							descText = descText .. L["|cfffed000Please note this module will only be enabled when the addon \"BeanCounter\" is enabled. This module will be disabled when BeanCounter could not be found and enabled when it can unless you manually disabled this module.|r"] .. "\n\n";
 							
 							-- Final warning
-							descText = descText .. "|cffff0000You are strongly adviced to leave this module enabled unless you have very good reasons not to.|r\n\n";
+							descText = descText .. L["|cffff0000You are strongly adviced to leave this module enabled unless you have very good reasons not to.|r"] .. "\n\n";
 							
 							if self:IsEnabled() then
-								descText = descText .. "Status: |cff00ff00Enabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cff00ff00Enabled|r"]);
 							else
-								descText = descText .. "Status: |cffff0000Disabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cffff0000Disabled|r"]);
 							end
 							
 							return descText;
@@ -139,12 +139,12 @@
 						type = "execute",
 						name = function()
 							if self:IsEnabled() then
-								return "Disable Module";
+								return L["Disable Module"];
 							else
-								return "Enable Module";
+								return L["Enable Module"];
 							end
 						end,
-						desc = "Click here to completely toggle this module on or off.",
+						desc = L["Click here to completely toggle this module on or off."],
 						width = "double",
 						func = function()
 							if self:IsEnabled() then
@@ -159,7 +159,7 @@
 						end,
 						confirm = function()
 							if self:IsEnabled() then
-								return "Are you sure you want to disable this module?\n\nIt will only be active when needed and disabling it may cause your BeanCounter data to become incomplete. Leaving it on causes no harm.";
+								return L["Are you sure you want to disable this module?\n\nIt will only be active when needed and disabling it may cause your BeanCounter data to become incomplete. Leaving it on causes no harm."];
 							else
 								return false;
 							end
--- a/Modules/Collected.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Modules/Collected.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,7 +1,7 @@
 local MailOpener = LibStub("AceAddon-3.0"):GetAddon("MailOpener");
 local mod = MailOpener:NewModule("Collected", "AceEvent-3.0", "AceTimer-3.0");
 
-mod.moduleDescription = "Shows a simple summary of what has been collected at the mailbox.";
+mod.moduleDescription = L["Shows a simple summary of what has been collected at the mailbox."];
 mod.moduleRequired = false;
 
 -- Gold
@@ -239,40 +239,40 @@
 			local timeSpentMinutes = floor( timeSpent / 60 );
 			local timeSpentSeconds = ( timeSpent % 60 );
 			if timeSpentMinutes ~= 0 then
-				printMessage = printMessage .. format("Collected a total of %d mail within %d minutes and %d seconds. ", mailOpened, timeSpentMinutes, timeSpentSeconds);
+				printMessage = printMessage .. format(L["Collected a total of %d mail within %d minutes and %d seconds."], mailOpened, timeSpentMinutes, timeSpentSeconds) .. " ";
 			else
-				printMessage = printMessage .. format("Collected a total of %d mail within %d seconds. ", mailOpened, timeSpentSeconds);
+				printMessage = printMessage .. format("Collected a total of %d mail within %d seconds.", mailOpened, timeSpentSeconds) .. " ";
 			end
 		else
-			printMessage = printMessage .. format("Collected a total of %d mail. ", mailOpened);
+			printMessage = printMessage .. format(L["Collected a total of %d mail."], mailOpened) .. " ";
 		end
 	elseif timeSpent and timeSpent > 0 then
 		local timeSpentMinutes = floor( timeSpent / 60 );
 		local timeSpentSeconds = ( timeSpent % 60 );
 		if timeSpentMinutes ~= 0 then
-			printMessage = printMessage .. format("Spent %d minutes and %d seconds collecting mail. ", mailOpened, timeSpentMinutes, timeSpentSeconds);
+			printMessage = printMessage .. format(L["Spent %d minutes and %d seconds collecting mail."], mailOpened, timeSpentMinutes, timeSpentSeconds) .. " ";
 		else
-			printMessage = printMessage .. format("Spent %d seconds collecting mail. ", mailOpened, timeSpentSeconds);
+			printMessage = printMessage .. format(L["Spent %d seconds collecting mail."], mailOpened, timeSpentSeconds) .. " ";
 		end
 	end
 	
 	-- Did we record any items or gold being looted?
 	if (itemsGained and itemsGained > 0) and (earned and earned > 0) then
-		printMessage = printMessage .. format("You gained %d items and %s from this.", itemsGained, MailOpener:FormatMoney(earned));
+		printMessage = printMessage .. format(L["You gained %d items and %s from this."], itemsGained, MailOpener:FormatMoney(earned));
 	elseif itemsGained and itemsGained > 0 then
-		printMessage = printMessage .. format("You gained %d items from this.", itemsGained);
+		printMessage = printMessage .. format(L["You gained %d items from this."], itemsGained);
 	elseif earned and earned > 0 then
-		printMessage = printMessage .. format("You gained %s from this.", MailOpener:FormatMoney(earned));
+		printMessage = printMessage .. format(L["You gained %s from this."], MailOpener:FormatMoney(earned));
 	end
 	
 	-- Did we record anything? print that!
 	if printMessage ~= "" then
-		print("|cff15ff00Mail Opener|r: " .. printMessage);
+		MailOpener:Print(printMessage);
 	end
 	
 	if self.db.profile.sessionSummary and ((sessionMailOpened and (not mailOpened or sessionMailOpened > mailOpened)) or (sessionTimeSpent and (not timeSpent or sessionTimeSpent > timeSpent)) or (sessionEarned and (not earned or sessionEarned > earned)) or (sessionItemsgained and (not itemsGained or sessionItemsgained > itemsGained))) then
 		-- Message buffer, append details we have data for
-		printMessage = "|cff15ff00Mail Opener|r: (Session summary) ";
+		printMessage = "(Session summary)" .. " ";
 	
 		-- Did we record any mail being opened?
 		if sessionMailOpened and sessionMailOpened > 0 then
@@ -281,35 +281,35 @@
 				local timeSpentMinutes = floor( sessionTimeSpent / 60 );
 				local timeSpentSeconds = ( sessionTimeSpent % 60 );
 				if timeSpentMinutes ~= 0 then
-					printMessage = printMessage .. format("Collected a total of %d mail within %d minutes and %d seconds this session. ", mailOpened, timeSpentMinutes, timeSpentSeconds);
+					printMessage = printMessage .. format(L["Collected a total of %d mail within %d minutes and %d seconds this session."], mailOpened, timeSpentMinutes, timeSpentSeconds) .. " ";
 				else
-					printMessage = printMessage .. format("Collected a total of %d mail within %d seconds this session. ", mailOpened, timeSpentSeconds);
+					printMessage = printMessage .. format(L["Collected a total of %d mail within %d seconds this session."], mailOpened, timeSpentSeconds) .. " ";
 				end
 			else
-				printMessage = printMessage .. format("Collected a total of %d mail this session. ", sessionMailOpened);
+				printMessage = printMessage .. format(L["Collected a total of %d mail this session."], sessionMailOpened) .. " ";
 			end
 		elseif sessionTimeSpent then
 			local timeSpentMinutes = floor( sessionTimeSpent / 60 );
 			local timeSpentSeconds = ( sessionTimeSpent % 60 );
 			if timeSpentMinutes ~= 0 then
-				printMessage = printMessage .. format("Spent %d minutes and %d seconds collecting mail this session. ", mailOpened, timeSpentMinutes, timeSpentSeconds);
+				printMessage = printMessage .. format(L["Spent %d minutes and %d seconds collecting mail this session."], mailOpened, timeSpentMinutes, timeSpentSeconds) .. " ";
 			else
-				printMessage = printMessage .. format("Spent %d seconds collecting mail this session. ", mailOpened, timeSpentSeconds);
+				printMessage = printMessage .. format(L["Spent %d seconds collecting mail this session."], mailOpened, timeSpentSeconds) .. " ";
 			end
 		end
 		
 		-- Did we record any items or gold being looted?
 		if (sessionItemsgained and sessionItemsgained > 0) and (sessionEarned and sessionEarned > 0) then
-			printMessage = printMessage .. format("You gained %d items and %s from this.", sessionItemsgained, MailOpener:FormatMoney(sessionEarned));
+			printMessage = printMessage .. format(L["You gained %d items and %s from this."], sessionItemsgained, MailOpener:FormatMoney(sessionEarned));
 		elseif sessionItemsgained and sessionItemsgained > 0 then
-			printMessage = printMessage .. format("You gained %d items from this.", sessionItemsgained);
+			printMessage = printMessage .. format(L["You gained %d items from this."], sessionItemsgained);
 		elseif sessionEarned and sessionEarned > 0 then
-			printMessage = printMessage .. format("You gained %s from this.", MailOpener:FormatMoney(sessionEarned));
+			printMessage = printMessage .. format(L["You gained %s from this."], MailOpener:FormatMoney(sessionEarned));
 		end
 	
 		-- Did we record anything? print that!
 		if printMessage ~= "" then
-			print(printMessage);
+			MailOpener:Print(printMessage);
 		end
 	end
 end
@@ -327,25 +327,25 @@
 	local configGroup = {
 		order = 0,
 		type = "modulesSubGroup",
-		name = "Collected",
-		desc = "Change settings for the collected module.",
+		name = L["Collected"],
+		desc = L["Change settings for the collected module."],
 		args = {
 			General = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "General",
+				name = L["General"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
 						name = function()
-							local descText = "With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set.\n\n";
+							local descText = L["With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set."] .. "\n\n";
 							
 							if self:IsEnabled() then
-								descText = descText .. "Status: |cff00ff00Enabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cff00ff00Enabled|r"]);
 							else
-								descText = descText .. "Status: |cffff0000Disabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cffff0000Disabled|r"]);
 							end
 							
 							return descText;
@@ -356,12 +356,12 @@
 						type = "execute",
 						name = function()
 							if self:IsEnabled() then
-								return "Disable Module";
+								return L["Disable Module"];
 							else
-								return "Enable Module";
+								return L["Enable Module"];
 							end
 						end,
-						desc = "Click here to completely toggle this module on or off.",
+						desc = L["Click here to completely toggle this module on or off."],
 						width = "double",
 						func = function()
 							if self:IsEnabled() then
@@ -381,12 +381,12 @@
 				order = 20,
 				type = "group",
 				inline = true,
-				name = "Track Stats",
+				name = L["Track Stats"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "You can select what things to track. Toggling something off will stop tracking of it completely and reduce the resources used by Mail Opener (although you shouldn't notice a difference).",
+						name = L["You can select what things to track. Toggling something off will stop tracking of it completely and reduce the resources used by Mail Opener (although you shouldn't notice a difference)."],
 					},
 					AHHeader = {
 						order = 15,
@@ -396,8 +396,8 @@
 					trackGold = {
 						order = 20,
 						type = "toggle",
-						name = "Track |cfffed000gold gained|r",
-						desc = "Track the amount of gold gained and display it when closing the mailbox.",
+						name = L["Track |cfffed000gold gained|r"],
+						desc = L["Track the amount of gold gained and display it when closing the mailbox."],
 						set = function(i, v)
 							self.db.profile.trackGold = v;
 							
@@ -410,8 +410,8 @@
 					trackItems = {
 						order = 30,
 						type = "toggle",
-						name = "Track |cfffed000items gained|r",
-						desc = "Track the amount of items gained and display it when closing the mailbox.",
+						name = L["Track |cfffed000items gained|r"],
+						desc = L["Track the amount of items gained and display it when closing the mailbox."],
 						set = function(i, v)
 							self.db.profile.trackItems = v;
 							
@@ -424,8 +424,8 @@
 					trackMail = {
 						order = 40,
 						type = "toggle",
-						name = "Track |cfffed000mail opened|r",
-						desc = "Track the amount of mail received and display it when closing the mailbox.",
+						name = L["Track |cfffed000mail opened|r"],
+						desc = L["Track the amount of mail received and display it when closing the mailbox."],
 						set = function(i, v)
 							self.db.profile.trackMail = v;
 							
@@ -438,8 +438,8 @@
 					trackTimeSpent = {
 						order = 50,
 						type = "toggle",
-						name = "Track |cfffed000time spent|r",
-						desc = "Track the amount of time spent at the mailbox.",
+						name = L["Track |cfffed000time spent|r"],
+						desc = L["Track the amount of time spent at the mailbox."],
 						set = function(i, v)
 							self.db.profile.trackTimeSpent = v;
 							
@@ -455,13 +455,13 @@
 				order = 30,
 				type = "group",
 				inline = true,
-				name = "Summarize",
+				name = L["Summarize"],
 				args = {
 					sessionSummary = {
 						order = 20,
 						type = "toggle",
-						name = "Also show a summary of the recorded stats within the entire session",
-						desc = "Also show a summary of the recorded stats within the entire session (since your last login or /reload).",
+						name = L["Also show a summary of the recorded stats within the entire session"],
+						desc = L["Also show a summary of the recorded stats within the entire session (since your last login or /reload)."],
 						set = function(i, v)
 							self.db.profile.sessionSummary = v;
 							
@@ -475,8 +475,8 @@
 					batchSummary = {
 						order = 30,
 						type = "toggle",
-						name = "Show a summary of the recorded stats whenever it updated after opening the current batch has finished",
-						desc = "Show a summary of the recorded stats whenever it has been updated after opening the current batch of mails has finished.",
+						name = L["Show a summary of the recorded stats whenever it updated after opening the current batch has finished"],
+						desc = L["Show a summary of the recorded stats whenever it has been updated after opening the current batch of mails has finished."],
 						set = function(i, v)
 							self.db.profile.batchSummary = v;
 							
--- a/Modules/Config.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Modules/Config.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,7 +1,7 @@
 local MailOpener = LibStub("AceAddon-3.0"):GetAddon("MailOpener");
 local mod = MailOpener:NewModule("Config", "AceEvent-3.0", "AceTimer-3.0");
 
-mod.moduleDescription = "Builds and loads the config frame(s) and handles the slash commands. Automatically loaded when needed.";
+mod.moduleDescription = L["Builds and loads the config frame(s) and handles the slash commands. Automatically loaded when needed."];
 mod.moduleRequired = false;
 
 local Media = LibStub("LibSharedMedia-3.0");
@@ -30,16 +30,16 @@
 	
 	if MailOpener.db.global.currentTip == -1 and MailOpener.db.profile.general.continueOpening == false then
 		StaticPopupDialogs["MailOpenerFirstConfigUseConfirmBox"] = {
-			text = "Do you wish to enable \"continue opening mail\"? Read the tip at the bottom of the \"General\" config for more information.",
-			button1 = "Yes",
-			button2 = "No",
+			text = L["Do you wish to enable \"continue opening mail\"? Read the tip at the bottom of the \"General\" config for more information."],
+			button1 = L["Yes"],
+			button2 = L["No"],
 			OnAccept = function()
 				MailOpener.db.profile.general.continueOpening = true;
 				
-				print("|cff15ff00Mail Opener|r: Enabling the functionality. Remember you can always change this setting in the \"Open All\" config (|cff00ffff/mo c|r).");
+				MailOpener:Print(L["Enabling the functionality. Remember you can always change this setting in the \"Open All\" config (|cff00ffff/mo c|r)."]);
 			end,
 			OnCancel = function (_,reason)
-				print("|cff15ff00Mail Opener|r: You can always change this setting in the \"Open All\" config (|cff00ffff/mo c|r).");
+				MailOpener:Print(L["You can always change this setting in the \"Open All\" config (|cff00ffff/mo c|r)."]);
 			end,
 			timeout = 0,
 			whileDead = 1,
@@ -62,25 +62,25 @@
 	
 	-- Can't put this in the abive scope as the ADDONEnable vars would then always be empty
 	tip = {
-		"To make Mail Opener automatically continue the opening of a batch of mail that had previously been interupted, you will have to tick the \"|cfffed000Continue opening mail|r\"-box at the \"|cfffed000Open All|r\" config. By default Mail Opener will always automatically start opening mail right after a server refresh, but you will have to manually resume mail opening if it gets interupted (e.g. because you closed the mailbox or because your bags were full).",
-		"You can |cfffed000shift-click|r a mail icon to loot all attachments from that single mail.",
+		L["To make Mail Opener automatically continue the opening of a batch of mail that had previously been interrupted, you will have to tick the \"|cfffed000Continue opening mail|r\"-box at the \"|cfffed000Open All|r\" config. By default Mail Opener will always automatically start opening mail right after a server refresh, but you will have to manually resume mail opening if it gets interrupted (e.g. because you closed the mailbox or because your bags were full)."],
+		L["You can |cfffed000shift-click|r a mail icon to loot all attachments from that single mail."],
 		{
-			txt = "|cfffed000Postal|r allows you to return mail by |cfffed000alt-clicking|r the mail icon.",
+			txt = L["|cfffed000Postal|r allows you to return mail by |cfffed000alt-clicking|r the mail icon."],
 			shown = (MailOpener.PostalEnabled),
 		},
 		{
-			txt = "|cfffed000Mail Opener|r is not meant to be a full replacement of |cfffed000Postal|r, it will only handle the opening of your mail and you can run both addons simultaneously.",
+			txt = L["|cfffed000Mail Opener|r is not meant to be a full replacement of |cfffed000Postal|r, it will only handle the opening of your mail and you can run both addons simultaneously."],
 			shown = (MailOpener.PostalEnabled),
 		},
-		"You can click the time remaining text to get it into a popup dialog so you can copy it (with |cfffed000CTRL-C|r) and then paste it (with |cfffed000CTRL-V|r) elsewhere.",
+		L["You can click the time remaining text to get it into a popup dialog so you can copy it (with |cfffed000CTRL-C|r) and then paste it (with |cfffed000CTRL-V|r) elsewhere."],
 		{
-			txt = "If you are looking for an addon with many handy modifications for |cfffed000sending|r mail, you might want to consider |cfffed000Postal|r.",
+			txt = L["If you are looking for an addon with many handy modifications for |cfffed000sending|r mail, you might want to consider |cfffed000Postal|r."],
 			shown = (not MailOpener.PostalEnabled),
 		},
-		"|cfffed000Cost on Delivery|r and |cfffed000Blizzard|r mail will always be skipped, regardless of any filters.",
-		"|cfffed000Right-click|r the |cfffed000open all|r button to quickly adjust your mail opening filters.",
-		"|cfffed000Shift-click|r the |cfffed000open all|r button to temporarily override your filters and loot every single mail containing attachments and/or gold.",
-		"Please report |cfffed000issues|r and |cfffed000suggestions|r/|cfffed000requests|r at the |cfffed000CurseForge ticket tracker|r, I will try to process and respond to them all (you can find a link to the ticket tracker in the addon description at Curse).",
+		L["|cfffed000Cost on Delivery|r and |cfffed000Blizzard|r mail will always be skipped, regardless of any filters."],
+		L["|cfffed000Right-click|r the |cfffed000open all|r button to quickly adjust your mail opening filters."],
+		L["|cfffed000Shift-click|r the |cfffed000open all|r button to temporarily override your filters and loot every single mail containing attachments and/or gold."],
+		L["Please report |cfffed000issues|r and |cfffed000suggestions|r/|cfffed000requests|r at the |cfffed000CurseForge ticket tracker|r, I will try to process and respond to them all (you can find a link to the ticket tracker in the addon description at Curse)."],
 	};
 	
 	-- Remove any "hidden" tips
@@ -141,7 +141,7 @@
 			print("New debug channel created.");
 		end
 	else
-		print("Wrong command, available: /mo config (or /mo c)");
+		print(L["Wrong command, available: /mo config (or /mo c)"]);
 	end
 end
 
@@ -179,7 +179,7 @@
 function mod:GetOptions()
 	local options = {
 		type = "group",	
-		name = "Mail Opener",
+		name = L["Mail Opener"],
 		childGroups = "tree",
 		args = {
 		},
@@ -232,35 +232,35 @@
 		order = 400,
 		type = "group",
 		childGroups = "tree",
-		name = "Modules",
-		desc = "Change settings for modules or toggle them on or off.",
+		name = L["Modules"],
+		desc = L["Change settings for modules or toggle them on or off."],
 		args = {
 			General = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "Modules Status",
+				name = L["Modules Status"],
 				args = {
 					headerName = {
 						order = 0,
 						width = "normal",
 						type = "description",
 						fontSize = "medium",
-						name = "|cfffed000Module Name|r",
+						name = L["|cfffed000Module Name|r"],
 					},
 					headerStatus = {
 						order = 1,
 						width = "half",
 						type = "description",
 						fontSize = "medium",
-						name = "|cfffed000Status|r",
+						name = L["|cfffed000Status|r"],
 					},
 					headerDefault = {
 						order = 2,
 						width = "double",
 						type = "description",
 						fontSize = "medium",
-						name = "|cfffed000Default Status|r",
+						name = L["|cfffed000Default Status|r"],
 					},
 					headerseperator = {
 						order = 3,
@@ -295,9 +295,9 @@
 			fontSize = "medium",
 			name = function()
 				if module:IsEnabled() then
-					return "|cff00ff00Enabled|r";
+					return L["|cff00ff00Enabled|r"];
 				else
-					return "|cffff0000Disabled|r";
+					return L["|cffff0000Disabled|r"];
 				end
 			end,
 		};
@@ -310,13 +310,13 @@
 			name = function()
 				local desc = "";
 				if MailOpener.db.profile.modules[moduleName] == nil or MailOpener.db.profile.modules[moduleName] == true then
-					desc = "|cff00ff00Enabled|r";
+					desc = L["|cff00ff00Enabled|r"];
 				else
-					desc = "|cffff0000Disabled|r";
+					desc = L["|cffff0000Disabled|r"];
 				end
 				
 				if module.moduleRequired then
-					desc = desc .. " (Required module)";
+					desc = desc .. " " .. L["(Required module)"];
 				end
 				
 				return desc;
@@ -351,25 +351,25 @@
 	local generalConfigGroup = {
 		order = 100,
 		type = "group",
-		name = "General",
-		desc = "Change general Mail Opener settings.",
+		name = L["General"],
+		desc = L["Change general Mail Opener settings."],
 		args = {
 			-- General config inline group
 			generalConfig = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "General",
+				name = L["General"],
 				args = {
 					defaultStatus = {
 						order = 0,
 						type = "select",
-						name = "Default mail opener status",
-						desc = "Select the default Mail Opener status when you open a mailbox for the first time since your log on.",
+						name = L["Default mail opener status"],
+						desc = L["Select the default Mail Opener status when you open a mailbox for the first time since your log on."],
 						values = {
-							_enabled = "Completely enabled",
-							disabled = "Auto opening disabled",
-							xdisabled = "Addon Disabled",
+							_enabled = L["Completely enabled"],
+							disabled = L["Auto opening disabled"],
+							xdisabled = L["Addon Disabled"],
 						},
 						get = function() return MailOpener.db.profile.general.defaultStatus; end,
 						set = function(i, v) MailOpener.db.profile.general.defaultStatus = v; end,
@@ -377,12 +377,12 @@
 					defaultQAStatus = {
 						order = 10,
 						type = "select",
-						name = "Default QA Auto Mail status",
-						desc = "Select the default Quick Auctions auto mail status whenever you open a mailbox.",
+						name = L["Default QA Auto Mail status"],
+						desc = L["Select the default Quick Auctions auto mail status whenever you open a mailbox."],
 						values = {
-							__remember = "Remember",
-							_enabled = "Enabled",
-							disabled = "Disabled",
+							__remember = L["Remember"],
+							_enabled = L["Enabled"],
+							disabled = L["Disabled"],
 						},
 						get = function() return MailOpener.db.profile.general.defaultQAStatus; end,
 						set = function(i, v) MailOpener.db.profile.general.defaultQAStatus = v; end,
@@ -391,8 +391,8 @@
 					continueOpeningStackableItems = {
 						order = 15,
 						type = "toggle",
-						name = "Continue trying to open mail after your bags are full",
-						desc = "If there are a lot of stackable items in your mailbox (e.g. glyphs) you may want to toggle this option on.\n\nThis will cause your Blizzard error frame to get extremely spammy if there's a lot of mail remaining. With this disabled, Mail Opener will completely stop opening mail while your inventory is full.",
+						name = L["Continue trying to open mail after your bags are full"],
+						desc = L["If there are a lot of stackable items in your mailbox (e.g. glyphs) you may want to toggle this option on.\n\nThis will cause your Blizzard error frame to get extremely spammy if there's a lot of mail remaining. With this disabled, Mail Opener will completely stop opening mail while your inventory is full."],
 						width = "full",
 						get =  function() return MailOpener.db.profile.general.continueOpeningStackableItems; end,
 						set = function(i, v) MailOpener.db.profile.general.continueOpeningStackableItems = v; end,
@@ -400,8 +400,8 @@
 					showHelpTooltips = {
 						order = 17,
 						type = "toggle",
-						name = "Display help tooltips at the mailbox buttons added by Mail Opener.",
-						desc = "Display the help tooltips when hovering at any of the mailbox buttons added by Mail Opener.",
+						name = L["Display help tooltips at the mailbox buttons added by Mail Opener."],
+						desc = L["Display the help tooltips when hovering at any of the mailbox buttons added by Mail Opener."],
 						width = "full",
 						get =  function() return MailOpener.db.profile.general.showHelpTooltips; end,
 						set = function(i, v) MailOpener.db.profile.general.showHelpTooltips = v; end,
@@ -409,8 +409,8 @@
 					autoDisableQAAutoMail = {
 						order = 20,
 						type = "toggle",
-						name = "Turn Quick Auction's auto mail status |cffff0000off|r when opening mail",
-						desc = "Quick Auction's auto mail is buggy when using other mail opening addons. If you are collecting mail while auto mailer is enabled wrong items may be send to the wrong character.\n\nTo solve this you must disable Quick Auction's auto mail while opening mail and you can re-enable it when mail opening is finished.",
+						name = L["Turn Quick Auction's auto mail status |cffff0000off|r when opening mail"],
+						desc = L["Quick Auction's auto mail is buggy when using other mail opening addons. If you are collecting mail while auto mailer is enabled wrong items may be send to the wrong character.\n\nTo solve this you must disable Quick Auction's auto mail while opening mail and you can re-enable it when mail opening is finished."],
 						width = "full",
 						get =  function() return MailOpener.db.profile.general.autoDisableQAAutoMail; end,
 						set = function(i, v) MailOpener.db.profile.general.autoDisableQAAutoMail = v; end,
@@ -419,8 +419,8 @@
 					autoReenableQAAutoMail = {
 						order = 30,
 						type = "toggle",
-						name = "Turn Quick Auction's auto mail status |cff00ff00on|r after opening mail has finished",
-						desc = "Quick Auction's auto mail is buggy when using other mail opening addons. If you are collecting mail while auto mailer is enabled wrong items may be send to the wrong character.\n\nTo solve this you must disable Quick Auction's auto mail while opening mail and you can re-enable it when mail opening is finished.",
+						name = L["Turn Quick Auction's auto mail status |cff00ff00on|r after opening mail has finished"],
+						desc = L["Quick Auction's auto mail is buggy when using other mail opening addons. If you are collecting mail while auto mailer is enabled wrong items may be send to the wrong character.\n\nTo solve this you must disable Quick Auction's auto mail while opening mail and you can re-enable it when mail opening is finished."],
 						width = "full",
 						get = function() return MailOpener.db.profile.general.autoReenableQAAutoMail; end,
 						set = function(i, v) MailOpener.db.profile.general.autoReenableQAAutoMail = v; end,
@@ -430,8 +430,8 @@
 					autoSetBackQAAutoMail = {
 						order = 40,
 						type = "toggle",
-						name = "Set Quick Auction's auto mail status |cff00ffffback|r after opening mail has finished (remember it)",
-						desc = "Instead of always turning Quick Auction's auto mail on after mail opening you can choose to set it back to the value it was prior to opening mail.",
+						name = L["Set Quick Auction's auto mail status |cff00ffffback|r after opening mail has finished (remember it)"],
+						desc = L["Instead of always turning Quick Auction's auto mail on after mail opening you can choose to set it back to the value it was prior to opening mail."],
 						width = "full",
 						get = function() return MailOpener.db.profile.general.autoSetBackQAAutoMail; end,
 						set = function(i, v) MailOpener.db.profile.general.autoSetBackQAAutoMail = v; end,
@@ -445,12 +445,12 @@
 				order = 15,
 				type = "group",
 				inline = true,
-				name = "New Character Specfic Profile",
+				name = L["New Character Specific Profile"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "You can create a new profile to allow different behaviour for different characters. Imagine setting up a profile for your AH banker which will retrieve all sorts of mail containing items while other characters don't automatically open mail with items sent by other players.",
+						name = L["You can create a new profile to allow different behaviour for different characters. Imagine setting up a profile for your AH banker which will retrieve all sorts of mail containing items while other characters don't automatically open mail with items sent by other players."],
 					},
 					header = {
 						order = 15,
@@ -460,8 +460,8 @@
 					createNewProfile = {
 						order = 20,
 						type = "execute",
-						name = "Create a new character specific profile",
-						desc = "Create a new profile for this user. You can also make profile groups at the profiles tab to the left.",
+						name = L["Create a new character specific profile"],
+						desc = L["Create a new profile for this user. You can also make profile groups at the profiles tab to the left."],
 						width = "double",
 						func = function()
 							MailOpener.db:SetProfile(UnitName("player") .. " - " .. GetRealmName());
@@ -474,7 +474,7 @@
 				order = 20,
 				type = "group",
 				inline = true,
-				name = "Mail Opening Tip",
+				name = L["Mail Opening Tip"],
 				args = {
 					description = {
 						order = 10,
@@ -485,7 +485,7 @@
 					nextTip = {
 						order = 20,
 						type = "execute",
-						name = "Next Tip",
+						name = L["Next Tip"],
 						width = "half",
 						func = function() self:NextTip(); self:GetTip(); end,
 					},
@@ -501,20 +501,20 @@
 	local notificationsConfigGroup = {
 		order = 200,
 		type = "group",
-		name = "Notifications",
-		desc = "Toggle notifications.",
+		name = L["Notifications"],
+		desc = L["Toggle notifications."],
 		args = {
 			-- Notifications config inline group
 			nofitications = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "Notifications",
+				name = L["Notifications"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "Toggle which notification you wish to see.",
+						name = L["Notifications"],
 					},
 				},
 			}, -- end Notifications config inline group
@@ -524,31 +524,13 @@
 				order = 20,
 				type = "group",
 				inline = true,
-				name = "General Notifications",
+				name = L["General Notifications"],
 				args = {
-					--[[welcome = {
-						order = 20,
-						type = "toggle",
-						name = "Show message when |cfffed000opening the mailbox|r",
-						desc = "Print the welcome message whenever you open the mailbox.",
-						set = function(i, v) MailOpener.db.profile.notifications.welcome = v; end,
-						get = function() return MailOpener.db.profile.notifications.welcome; end,
-						width = "double",
-					},
-					bye = {
-						order = 21,
-						type = "toggle",
-						name = "Show message when |cfffed000closing the mailbox|r",
-						desc = "Print the bye message whenever you close the mailbox.",
-						set = function(i, v) MailOpener.db.profile.notifications.bye = v; end,
-						get = function() return MailOpener.db.profile.notifications.bye; end,
-						width = "double",
-					},]]
 					fishedOpeningBatch = {
 						order = 22,
 						type = "toggle",
-						name = "Announce when |cfffed000finished opening the current batch|r",
-						desc = "Announce when opening of the current batch of mail has been completed.",
+						name = L["Announce when |cfffed000finished opening the current batch|r"],
+						desc = L["Announce when opening of the current batch of mail has been completed."],
 						set = function(i, v) MailOpener.db.profile.notifications.finishedCurrentBatch = v; end,
 						get = function() return MailOpener.db.profile.notifications.finishedCurrentBatch; end,
 						width = "double",
@@ -556,8 +538,8 @@
 					noMoreMailAvailable = {
 						order = 23,
 						type = "toggle",
-						name = "Announce when |cfffed000the mailbox is completely empty|r",
-						desc = "Announce when there is nothing left for Mail Opener to open.",
+						name = L["Announce when |cfffed000the mailbox is completely empty|r"],
+						desc = L["Announce when there is nothing left for Mail Opener to open."],
 						set = function(i, v) MailOpener.db.profile.notifications.mailboxIsEmpty = v; end,
 						get = function() return MailOpener.db.profile.notifications.mailboxIsEmpty; end,
 						width = "double",
@@ -570,27 +552,27 @@
 				order = 30,
 				type = "group",
 				inline = true,
-				name = "Mail Skipped Notifications",
+				name = L["Mail Skipped Notifications"],
 				args = {
 					descriptionMailSkipped = {
 						order = 31,
 						type = "description",
-						name = "Announce when mail is skipped because...",
+						name = L["Announce when mail is skipped because..."],
 					},
 					
 					skippedToggleAll = {
 						order = 35,
 						type = "toggle",
-						name = "Toggle everything",
-						desc = "Announce when mail is skipped for |cfffed000any|r reason.",
+						name = L["Toggle everything"],
+						desc = L["Announce when mail is skipped for |cfffed000any|r reason."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.all = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.all; end,
 					},
 					skippedInventoryFull = {
 						order = 36,
 						type = "toggle",
-						name = "Your inventory is full",
-						desc = "Announce when mail is skipped because |cfffed000your inventory is full|r.",
+						name = L["Your inventory is full"],
+						desc = L["Announce when mail is skipped because |cfffed000your inventory is full|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.inventoryFull = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.inventoryFull; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -598,8 +580,8 @@
 					skippedKeepFreeSpaceLimit = {
 						order = 37,
 						type = "toggle",
-						name = "Keep free space limit reached",
-						desc = "Announce when mail is skipped because |cfffed000the keep free space limit has been reached|r.",
+						name = L["Keep free space limit reached"],
+						desc = L["Announce when mail is skipped because |cfffed000the keep free space limit has been reached|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.keepFreeSpaceLimit = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.keepFreeSpaceLimit; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -607,8 +589,8 @@
 					skippedGMMail = {
 						order = 38,
 						type = "toggle",
-						name = "GM mail",
-						desc = "Announce when mail is skipped because it's |cfffed000mail sent by a Game Master|r.",
+						name = L["Blizzard mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000mail sent by Blizzard|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.GMMail = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.GMMail; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -616,8 +598,8 @@
 					skippedCOD = {
 						order = 39,
 						type = "toggle",
-						name = "C.O.D. mail",
-						desc = "Announce when mail is skipped because it's |cfffed000a Cost On Delivery mail|r.",
+						name = L["C.O.D. mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000a Cost On Delivery mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.COD = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.COD; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -625,8 +607,8 @@
 					skippedNormalGoldMail = {
 						order = 40,
 						type = "toggle",
-						name = "Normal mail with gold",
-						desc = "Announce when mail is skipped because it's |cfffed000normal mail containing gold|r.",
+						name = L["Normal mail with gold"],
+						desc = L["Announce when mail is skipped because it's |cfffed000normal mail containing gold|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.normalGoldMail = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.normalGoldMail; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -634,8 +616,8 @@
 					skippedNormalItemsMail = {
 						order = 41,
 						type = "toggle",
-						name = "Normal mail with attachments",
-						desc = "Announce when mail is skipped because it's |cfffed000normal mail containing items|r.",
+						name = L["Normal mail with attachments"],
+						desc = L["Announce when mail is skipped because it's |cfffed000normal mail containing items|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.normalItemsMail = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.normalItemsMail; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -643,8 +625,8 @@
 					skippedAHExpired = {
 						order = 42,
 						type = "toggle",
-						name = "Auction expired mail",
-						desc = "Announce when mail is skipped because it's |cfffed000auction expired mail|r.",
+						name = L["Auction expired mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000auction expired mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.AHexpired = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.AHexpired; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -652,8 +634,8 @@
 					skippedAHSuccessful = {
 						order = 43,
 						type = "toggle",
-						name = "Auction successful mail",
-						desc = "Announce when mail is skipped because it's |cfffed000auction successful mail|r.",
+						name = L["Auction successful mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000auction successful mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.AHsuccess = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.AHsuccess; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -661,8 +643,8 @@
 					skippedAHWon = {
 						order = 44,
 						type = "toggle",
-						name = "Auction won mail",
-						desc = "Announce when mail is skipped because it's |cfffed000auction won mail|r.",
+						name = L["Auction won mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000auction won mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.AHwon = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.AHwon; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -670,8 +652,8 @@
 					skippedAHCanceled = {
 						order = 45,
 						type = "toggle",
-						name = "Auction canceled mail",
-						desc = "Announce when mail is skipped because it's |cfffed000auction canceled mail|r.",
+						name = L["Auction canceled mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000auction canceled mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.AHcanceled = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.AHcanceled; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -679,8 +661,8 @@
 					skippedAHOutbid = {
 						order = 46,
 						type = "toggle",
-						name = "Auction outbid mail",
-						desc = "Announce when mail is skipped because it's |cfffed000auction outbid mail|r.",
+						name = L["Auction outbid mail"],
+						desc = L["Announce when mail is skipped because it's |cfffed000auction outbid mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.AHoutbid = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.AHoutbid; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -688,8 +670,8 @@
 					skippedOther = {
 						order = 47,
 						type = "toggle",
-						name = "Other mail (e.g. plain text)",
-						desc = "Announce when mail is skipped because it's |cfffed000any other kind of mail|r (e.g. plain text).",
+						name = L["Other mail (e.g. plain text)"],
+						desc = L["Announce when mail is skipped because it's |cfffed000any other kind of mail|r (e.g. plain text)."],
 						set = function(i, v) MailOpener.db.profile.notifications.skipped.other = v; end,
 						get = function() return MailOpener.db.profile.notifications.skipped.other; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.skipped.all); end,
@@ -702,27 +684,27 @@
 				order = 40,
 				type = "group",
 				inline = true,
-				name = "Mail Processed Notifications",
+				name = L["Mail Processed Notifications"],
 				args = {
 					descriptionMailProcessed = {
 						order = 61,
 						type = "description",
-						name = "Announce when mail is processed because...",
+						name = L["Announce when mail is processed because..."],
 					},
 					
 					processedToggleAll = {
 						order = 65,
 						type = "toggle",
-						name = "Toggle everything",
-						desc = "Announce when mail is processed for |cfffed000any|r reason.",
+						name = L["Toggle everything"],
+						desc = L["Announce when mail is processed for |cfffed000any|r reason."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.all = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.all; end,
 					},
 					processedNormalGoldMail = {
 						order = 70,
 						type = "toggle",
-						name = "Normal mail with gold",
-						desc = "Announce when mail is processed because it's |cfffed000normal mail containing gold|r.",
+						name = L["Normal mail with gold"],
+						desc = L["Announce when mail is processed because it's |cfffed000normal mail containing gold|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.normalGoldMail = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.normalGoldMail; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -730,8 +712,8 @@
 					processedNormalItemsMail = {
 						order = 71,
 						type = "toggle",
-						name = "Normal mail with attachments",
-						desc = "Announce when mail is processed because it's |cfffed000normal mail containing items|r.",
+						name = L["Normal mail with attachments"],
+						desc = L["Announce when mail is processed because it's |cfffed000normal mail containing items|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.normalItemsMail = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.normalItemsMail; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -739,8 +721,8 @@
 					processedAHExpired = {
 						order = 72,
 						type = "toggle",
-						name = "Auction expired mail",
-						desc = "Announce when mail is processed because it's |cfffed000auction expired mail|r.",
+						name = L["Auction expired mail"],
+						desc = L["Announce when mail is processed because it's |cfffed000auction expired mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.AHexpired = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.AHexpired; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -748,8 +730,8 @@
 					processedAHSuccessful = {
 						order = 73,
 						type = "toggle",
-						name = "Auction successful mail",
-						desc = "Announce when mail is processed because it's |cfffed000auction successful mail|r.",
+						name = L["Auction successful mail"],
+						desc = L["Announce when mail is processed because it's |cfffed000auction successful mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.AHsuccess = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.AHsuccess; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -757,8 +739,8 @@
 					processedAHWon = {
 						order = 74,
 						type = "toggle",
-						name = "Auction won mail",
-						desc = "Announce when mail is processed because it's |cfffed000auction won mail|r.",
+						name = L["Auction won mail"],
+						desc = L["Announce when mail is processed because it's |cfffed000auction won mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.AHwon = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.AHwon; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -766,8 +748,8 @@
 					processedAHCanceled = {
 						order = 75,
 						type = "toggle",
-						name = "Auction canceled mail",
-						desc = "Announce when mail is processed because it's |cfffed000auction canceled mail|r.",
+						name = L["Auction canceled mail"],
+						desc = L["Announce when mail is processed because it's |cfffed000auction canceled mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.AHcanceled = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.AHcanceled; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -775,8 +757,8 @@
 					processedAHOutbid = {
 						order = 76,
 						type = "toggle",
-						name = "Auction outbid mail",
-						desc = "Announce when mail is processed because it's |cfffed000auction outbid mail|r.",
+						name = L["Auction outbid mail"],
+						desc = L["Announce when mail is processed because it's |cfffed000auction outbid mail|r."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.AHoutbid = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.AHoutbid; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -784,8 +766,8 @@
 					processedOther = {
 						order = 77,
 						type = "toggle",
-						name = "Other mail (e.g. plain text)",
-						desc = "Announce when mail is processed because it's |cfffed000any other kind of mail|r (e.g. plain text).",
+						name = L["Other mail (e.g. plain text)"],
+						desc = L["Announce when mail is processed because it's |cfffed000any other kind of mail|r (e.g. plain text)."],
 						set = function(i, v) MailOpener.db.profile.notifications.processed.other = v; end,
 						get = function() return MailOpener.db.profile.notifications.processed.other; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.processed.all); end,
@@ -798,18 +780,18 @@
 				order = 50,
 				type = "group",
 				inline = true,
-				name = "Sound Notifications",
+				name = L["Sound Notifications"],
 				args = {
 					descriptionMailProcessed = {
 						order = 61,
 						type = "description",
-						name = "Play a sound when...",
+						name = L["Play a sound when..."],
 					},
 					bagsFullSound = {
 						order = 100,
 						type = "toggle",
-						name = "Inventory is full",
-						desc = "Play a sound when your inventory is full. You can select what sound in the select box next to this.",
+						name = L["Inventory is full"],
+						desc = L["Play a sound when your inventory is full. You can select what sound in the select box next to this."],
 						set = function(i, v) MailOpener.db.profile.notifications.bagsFullSound = v; end,
 						get = function() return MailOpener.db.profile.notifications.bagsFullSound; end,
 						width = "medium",
@@ -817,8 +799,8 @@
 					bagsFullSoundFile = {
 						order = 101,
 						type = "select",
-						name = "Sound File",
-						desc = "Sound file to play when your bags are full.",
+						name = L["Sound File"],
+						desc = L["Sound file to play when your bags are full."],
 						dialogControl = "LSM30_Sound",
 						set = function(i, v)
 							MailOpener.db.profile.notifications.bagsFullSoundFile = Media:Fetch("sound", v);
@@ -826,7 +808,7 @@
 							
 							PlaySoundFile(MailOpener.db.profile.notifications.bagsFullSoundFile);
 							
-							print("|cff15ff00Mail Opener|r: You may have to increase the mail opening interval if this sound effect gets spammy. The recommended value is 10 seconds.");
+							MailOpener:Print(L["You may have to increase the mail opening interval if this sound effect gets spammy. The recommended value is 10 seconds."]);
 						end,
 						get = function() return MailOpener.db.profile.notifications.bagsFullSoundFileName end,
 						values = function () return (Media:HashTable("sound") or nil); end,
@@ -835,8 +817,8 @@
 					bagsFullSoundOnlyOnce = {
 						order = 102,
 						type = "toggle",
-						name = "Only once",
-						desc = "Only play this sound once each time new mail has been arrived or your bags are updated.",
+						name = L["Only once"],
+						desc = L["Only play this sound once each time new mail has been arrived or your bags are updated."],
 						set = function(i, v) MailOpener.db.profile.notifications.bagsFullSoundOnlyOnce = v; end,
 						get = function() return MailOpener.db.profile.notifications.bagsFullSoundOnlyOnce; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.bagsFullSound); end,
@@ -845,8 +827,8 @@
 					bagsFullSoundOnlyOncePerMailboxVisit = {
 						order = 103,
 						type = "toggle",
-						name = "...per mailbox visit",
-						desc = "Only play this sound once each time you visit the mailbox.",
+						name = L["...per mailbox visit"],
+						desc = L["Only play this sound once each time you visit the mailbox."],
 						set = function(i, v) MailOpener.db.profile.notifications.bagsFullSoundOnlyOncePerMailboxVisit = v; end,
 						get = function() return MailOpener.db.profile.notifications.bagsFullSoundOnlyOncePerMailboxVisit; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.bagsFullSound or not MailOpener.db.profile.notifications.bagsFullSoundOnlyOnce); end,
@@ -854,8 +836,8 @@
 					mailboxEmptySound = {
 						order = 110,
 						type = "toggle",
-						name = "No more mail can be opened",
-						desc = "Play a sound when no more mail can be opened. You can select what sound in the select box next to this.",
+						name = L["No more mail can be opened"],
+						desc = L["Play a sound when no more mail can be opened. You can select what sound in the select box next to this."],
 						set = function(i, v) MailOpener.db.profile.notifications.mailboxEmptySound = v; end,
 						get = function() return MailOpener.db.profile.notifications.mailboxEmptySound; end,
 						--width = "double",
@@ -863,8 +845,8 @@
 					mailboxEmptySoundFile = {
 						order = 111,
 						type = "select",
-						name = "Sound File",
-						desc = "Sound file to play when Mail Opener can't open any more mail.",
+						name = L["Sound File"],
+						desc = L["Sound file to play when Mail Opener can't open any more mail."],
 						dialogControl = "LSM30_Sound",
 						set = function(i, v)
 							MailOpener.db.profile.notifications.mailboxEmptySoundFile = Media:Fetch("sound", v);
@@ -872,7 +854,7 @@
 							
 							PlaySoundFile(MailOpener.db.profile.notifications.mailboxEmptySoundFile);
 							
-							print("|cff15ff00Mail Opener|r: You may have to increase the mail opening interval if this sound effect gets spammy. The recommended value is 10 seconds.");
+							MailOpener:Print(L["You may have to increase the mail opening interval if this sound effect gets spammy. The recommended value is 10 seconds."]);
 						end,
 						get = function() return MailOpener.db.profile.notifications.mailboxEmptySoundFileName end,
 						values = function () return (Media:HashTable("sound") or nil); end,
@@ -881,8 +863,8 @@
 					mailboxEmptySoundOnlyOnce = {
 						order = 112,
 						type = "toggle",
-						name = "Only once",
-						desc = "Only play this sound once each time new mail has been arrived.",
+						name = L["Only once"],
+						desc = L["Only play this sound once each time new mail has been arrived."],
 						set = function(i, v) MailOpener.db.profile.notifications.mailboxEmptySoundOnlyOnce = v; end,
 						get = function() return MailOpener.db.profile.notifications.mailboxEmptySoundOnlyOnce; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.mailboxEmptySound); end,
@@ -891,8 +873,8 @@
 					mailboxEmptySoundOnlyOncePerMailboxVisit = {
 						order = 113,
 						type = "toggle",
-						name = "...per mailbox visit",
-						desc = "Only play this sound once each time you visit the mailbox.",
+						name = L["...per mailbox visit"],
+						desc = L["Only play this sound once each time you visit the mailbox."],
 						set = function(i, v) MailOpener.db.profile.notifications.mailboxEmptySoundOnlyOncePerMailboxVisit = v; end,
 						get = function() return MailOpener.db.profile.notifications.mailboxEmptySoundOnlyOncePerMailboxVisit; end,
 						disabled = function() return (not MailOpener.db.profile.notifications.bagsFullSound or not MailOpener.db.profile.notifications.mailboxEmptySoundOnlyOnce); end,
--- a/Modules/FailSafe.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Modules/FailSafe.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,7 +1,7 @@
 local MailOpener = LibStub("AceAddon-3.0"):GetAddon("MailOpener");
 local mod = MailOpener:NewModule("FailSafe", "AceEvent-3.0", "AceTimer-3.0");
 
-mod.moduleDescription = "Prevents the mail opening from completely stopping when the opening of a single mail gets stuck.";
+mod.moduleDescription = L["Prevents the mail opening from completely stopping when the opening of a single mail gets stuck."];
 mod.moduleRequired = false;
 
 function mod:OnInitialize()
@@ -74,32 +74,32 @@
 function mod:Continue()
 	MailOpener:GetModule("OpenAll"):Continue();
 	
-	print("|cff15ff00Mail Opener|r (FailSafe): Mail opening timeout, continueing with the next mail.");
+	MailOpener:Print(L["(FailSafe) Mail opening timeout, continuing with the next mail."]);
 end
 
 function mod:GetOptionsGroup()
 	local configGroup = {
 		order = 0,
 		type = "modulesSubGroup",
-		name = "FailSafe",
-		desc = "Change settings for the FailSafe module.",
+		name = L["FailSafe"],
+		desc = L["Change settings for the FailSafe module."],
 		args = {
 			General = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "General",
+				name = L["General"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
 						name = function()
-							local descText = "With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set.\n\n";
+							local descText = L["With this button you can completely toggle this module |cff00ff00on|r or |cffff0000off|r. This setting will be remembered and the module will be automatically toggled |cff00ff00on|r or |cffff0000off|r upon logon as it was last set."] .. "\n\n";
 							
 							if self:IsEnabled() then
-								descText = descText .. "Status: |cff00ff00Enabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cff00ff00Enabled|r"]);
 							else
-								descText = descText .. "Status: |cffff0000Disabled|r";
+								descText = descText .. L["Status: %s"]:format(L["|cffff0000Disabled|r"]);
 							end
 							
 							return descText;
@@ -110,12 +110,12 @@
 						type = "execute",
 						name = function()
 							if self:IsEnabled() then
-								return "Disable Module";
+								return L["Disable Module"];
 							else
-								return "Enable Module";
+								return L["Enable Module"];
 							end
 						end,
-						desc = "Click here to completely toggle this module on or off.",
+						desc = L["Click here to completely toggle this module on or off."],
 						width = "double",
 						func = function()
 							if self:IsEnabled() then
@@ -135,12 +135,12 @@
 				order = 20,
 				type = "group",
 				inline = true,
-				name = "Single Mail Opening Timeout",
+				name = L["Single Mail Opening Timeout"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "Change how long FailSafe should wait before skipping the last mail and continueing with the next. This will prevent mail opening getting stuck forever because a single mail is frozen for whatever reason.",
+						name = L["Change how long FailSafe should wait before skipping the last mail and continuing with the next. This will prevent mail opening getting stuck forever because a single mail is frozen for whatever reason."],
 					},
 					timeout = {
 						order = 20,
@@ -149,8 +149,8 @@
 						min = 1,
 						max = 60,
 						step = 0.5,
-						name = "Single Mail Timeout",
-						desc = "Change how long FailSafe should wait before skipping the last mail and continueing with the next. This should prevent mail opening getting stuck because a single mail is stuck for whatever reason.\n\nDefault value is 20 seconds.",
+						name = L["Single Mail Timeout"],
+						desc = L["Change how long FailSafe should wait before skipping the last mail and continuing with the next. This should prevent mail opening getting stuck because a single mail is stuck for whatever reason.\n\nDefault value is 20 seconds."],
 						get = function() return self.db.profile.timeout; end,
 						set = function(i, v) self.db.profile.timeout = v; end,
 					},
--- a/Modules/OpenAll.lua	Tue Sep 14 11:17:38 2010 +0200
+++ b/Modules/OpenAll.lua	Wed Sep 15 13:10:56 2010 +0200
@@ -1,7 +1,8 @@
 local MailOpener = LibStub("AceAddon-3.0"):GetAddon("MailOpener");
 local mod = MailOpener:NewModule("OpenAll", "AceEvent-3.0", "AceTimer-3.0");
+local L = LibStub("AceLocale-3.0"):GetLocale("MailOpener");
 
-mod.moduleDescription = "The actual mail opening initiated by the core.";
+mod.moduleDescription = L["The actual mail opening initiated by the core."];
 mod.moduleRequired = true;
 
 --[[
@@ -41,7 +42,7 @@
 	if not self.btnOpenAll then
 		-- Open all button
 		local button = CreateFrame("Button", "btnMailOpenerOpenAll", InboxFrame, "UIPanelButtonTemplate");
-		button:SetText("Open all");
+		button:SetText(L["Open all"]);
 		button:SetHeight(26);
 		button:SetWidth(120);
 		button:SetPoint("BOTTOM", InboxFrame, "CENTER", -10, -165);
@@ -63,7 +64,7 @@
 					    if level == 1 then
 							-- Create the title of the menu
 							info.isTitle = true;
-							info.text = "Toggle filters for " .. MailOpener.db:GetCurrentProfile() .. " profile.";
+							info.text = L["Toggle filters for %s profile."]:format(MailOpener.db:GetCurrentProfile());
 							info.notCheckable = true;
 							UIDropDownMenu_AddButton(info, level);
 							
@@ -76,43 +77,43 @@
 							info.keepShownOnClick = true;
 							
 							-- Make Auction canceled option
-							info.text = "Auction canceled";
+							info.text = L["Auction canceled"];
 							info.func = function(this) mod.db.profile.filter.AH.canceled = this.checked; end;
 							info.checked = mod.db.profile.filter.AH.canceled;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Auction expired option
-							info.text = "Auction expired";
+							info.text = L["Auction expired"];
 							info.func = function(this) mod.db.profile.filter.AH.expired = this.checked; end;
 							info.checked = mod.db.profile.filter.AH.expired;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Auction outbid option
-							info.text = "Auction outbid";
+							info.text = L["Auction outbid"];
 							info.func = function(this) mod.db.profile.filter.AH.outbid = this.checked; end;
 							info.checked = mod.db.profile.filter.AH.outbid;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Auction successful option
-							info.text = "Auction successful";
+							info.text = L["Auction successful"];
 							info.func = function(this) mod.db.profile.filter.AH.success = this.checked; end;
 							info.checked = mod.db.profile.filter.AH.success;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Auction won option
-							info.text = "Auction won";
+							info.text = L["Auction won"];
 							info.func = function(this) mod.db.profile.filter.AH.won = this.checked; end;
 							info.checked = mod.db.profile.filter.AH.won;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Other mail with attachments
-							info.text = "Other mail with attachments";
+							info.text = L["Other mail with attachments"];
 							info.func = function(this) mod.db.profile.filter.normalAttachments = this.checked; end;
 							info.checked = mod.db.profile.filter.normalAttachments;
 							UIDropDownMenu_AddButton(info, level);
 							
 							-- Make Other mail with gold
-							info.text = "Other mail with gold";
+							info.text = L["Other mail with gold"];
 							info.func = function(this) mod.db.profile.filter.normalMoney = this.checked; end;
 							info.checked = mod.db.profile.filter.normalMoney;
 							UIDropDownMenu_AddButton(info, level);
@@ -136,8 +137,8 @@
 				mod:Open(true, IsShiftKeyDown());
 			end
 		end);
-		button.tooltipTitle = "Open all";
-		button.tooltip = "Hold |cfffed000shift|r while clicking this button to temporarily override your filters and loot every single mail containing attachments and/or gold.\n\n|cfffed000Right|r click this button to quickly adjust mail opening filters for this profile.";
+		button.tooltipTitle = L["Open all"];
+		button.tooltip = L["Hold |cfffed000shift|r while clicking this button to temporarily override your filters and loot every single mail containing attachments and/or gold.\n\n|cfffed000Right|r click this button to quickly adjust mail opening filters for this profile."];
 		button:SetScript("OnEnter", function(self)
 			if MailOpener.db.profile.general.showHelpTooltips then
 				GameTooltip:SetOwner(self, "ANCHOR_NONE")
@@ -380,7 +381,7 @@
 			if everything and self.db.profile.filter.allowShiftClick then
 				MAIL_OPEN_EVERYTHING = true;
 				
-				print("|cff15ff00Mail Opener|r: Shift key was held while pressing the open all button. Temporarily overriding filters; going to open every mail with attachments.");
+				MailOpener:Print(L["Shift key was held while pressing the open all button. Temporarily overriding filters; going to open every mail with attachments."]);
 			else
 				MAIL_OPEN_EVERYTHING = nil;
 			end
@@ -392,7 +393,7 @@
 			self:OpenNext();
 		else
 			if MailOpener.db.profile.notifications.mailboxIsEmpty then
-				print("|cffff0000There is currently no mail available.|r");
+				print(L["|cffff0000There is currently no mail available.|r"]);
 			end
 			
 			self:Debug("MO_OPEN_COMPLETE");
@@ -431,16 +432,20 @@
 end
 
 function mod:OpenMail(index)
-	if index > 0 then
+	if index and index > 0 then
 		-- LUA arrays start at 1, so mail with index 0 doesn't exist, so we're finished
 		
 		local sender, subject, gold, cod, _, items, _, _, _, _, isGM = select(3, GetInboxHeaderInfo(index));
 		local auctionMailType = self:GetAuctionMailType(subject);
 		
+		if not subject then subject = ""; end
+		
+		local skippingString = L["Skipping %d: %s (%s)"];
+		
 		if isGM then
-			-- GM Mail
+			-- Blizzard Mail
 			if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped.GMMail then
-				print("Skipping " .. index .. ": " .. subject .. " (GM mail)");
+				print(skippingString:format(index, subject, L["Blizzard mail"]));
 			end
 			
 			self:OpenNext();
@@ -449,7 +454,7 @@
 		elseif cod and cod > 0 then
 			-- Cost on delivery
 			if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped.COD then
-				print("Skipping " .. index .. ": " .. subject .. " (C.O.D.)");
+				print(skippingString:format(index, subject, L["C.O.D."]));
 			end
 			
 			self:OpenNext();
@@ -468,7 +473,7 @@
 			
 			if inventoryFull and not MAIL_OPEN_EVERYTHING and not MailOpener.db.profile.general.continueOpeningStackableItems and items and items > 0 then
 				if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped.inventoryFull then
-					print("Skipping " .. index .. ": " .. subject .. " (inventory is full)");
+					print(skippingString:format(index, subject, L["inventory is full"]));
 				end
 				
 				self:OpenNext();
@@ -476,7 +481,7 @@
 				return;
 			elseif self.db.profile.keepFreeSpace > 0 and items and ( slotsAvailable - items ) < self.db.profile.keepFreeSpace then
 				if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped.keepFreeSpaceLimit then
-					print("Skipping " .. index .. ": " .. subject .. " (keep free space limit)");
+					print(skippingString:format(index, subject, L["keep free space limit"]));
 				end
 				
 				self:OpenNext();
@@ -502,7 +507,7 @@
 				
 				if not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.normalMoney and mailType == "normalGoldMail" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (normal mail with gold)");
+						print(skippingString:format(index, subject, L["normal mail with gold"]));
 					end
 					
 					self:OpenNext();
@@ -510,7 +515,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.normalAttachments and mailType == "normalItemsMail" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (normal mail with attachments)");
+						print(skippingString:format(index, subject, L["normal mail with attachments"]));
 					end
 					
 					self:OpenNext();
@@ -518,7 +523,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.AH.expired and mailType == "AHexpired" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (expired auction)");
+						print(skippingString:format(index, subject, L["expired auction"]));
 					end
 					
 					self:OpenNext();
@@ -526,7 +531,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.AH.success and mailType == "AHsuccess" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (successful auction)");
+						print(skippingString:format(index, subject, L["successful auction"]));
 					end
 					
 					self:OpenNext();
@@ -534,7 +539,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.AH.won and mailType == "AHwon" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (auction won)");
+						print(skippingString:format(index, subject, L["auction won"]));
 					end
 					
 					self:OpenNext();
@@ -542,7 +547,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.AH.canceled and mailType == "AHcanceled" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (canceled auction)");
+						print(skippingString:format(index, subject, L["canceled auction"]));
 					end
 					
 					self:OpenNext();
@@ -550,7 +555,7 @@
 					return;
 				elseif not MAIL_OPEN_EVERYTHING and not self.db.profile.filter.AH.outbid and mailType == "AHoutbid" then
 					if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped[mailType] then
-						print("Skipping " .. index .. ": " .. subject .. " (outbid on auction)");
+						print(skippingString:format(index, subject, L["outbid on auction"]));
 					end
 					
 					self:OpenNext();
@@ -569,9 +574,9 @@
 					
 					if MailOpener.db.profile.notifications.processed.all and MailOpener.db.profile.notifications.processed[mailType] then
 						if gold and gold > 0 then
-							print("Processing " .. index .. ": " .. subject .. " (" .. MailOpener:FormatMoney(gold) .. ")");
+							print(L["Processing %d: %s (%s)"]:format(index, subject, MailOpener:FormatMoney(gold)));
 						else
-							print("Processing " .. index .. ": " .. subject);
+							print(L["Processing %d: %s"]:format(index, subject));
 						end
 					end
 					
@@ -582,11 +587,7 @@
 		else
 			-- Unknown, probably just text
 			if MailOpener.db.profile.notifications.skipped.all and MailOpener.db.profile.notifications.skipped.other then
-				if subject then
-					print("Skipping " .. index .. ": " .. subject);
-				else
-					print("Skipping " .. index);
-				end
+				print(L["Skipping %d: %s"]:format(index, subject));
 			end
 			
 			self:OpenNext();
@@ -594,7 +595,7 @@
 	else
 		-- Finished!
 		if MailOpener.db.profile.notifications.finishedCurrentBatch then
-			print("Finished opening the current batch.");
+			print(L["Finished opening the current batch."]);
 		end
 		
 		self:SetOpeningStatus(false);
@@ -628,13 +629,13 @@
 end
 
 local mailRemainingPatterns = {
-	minutesSeconds = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes and |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds).";
-	minutes = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes (next refresh in |cffffffff%d|r seconds).";
-	seconds = "|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds).";
-	nextRefresh = "|cffffffff%d|r/|cffffffff%d|r mail remaining, next refresh in |cffffffff%d|r seconds.";
-	waitingBatch = "|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for something from the current batch to be opened...";
-	waitingSync = "|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for the next mailbox refresh...";
-	soon = "|cffffffff%d|r/|cffffffff%d|r mail remaining - everything will be opened soon...";
+	minutesSeconds = L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes and |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)."],
+	minutes = L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r minutes (next refresh in |cffffffff%d|r seconds)."],
+	seconds = L["|cffffffff%d|r/|cffffffff%d|r mail remaining, opening everything will take about |cffffffff%d|r seconds (next refresh in |cffffffff%d|r seconds)."],
+	nextRefresh = L["|cffffffff%d|r/|cffffffff%d|r mail remaining, next refresh in |cffffffff%d|r seconds."],
+	waitingBatch = L["|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for something from the current batch to be opened..."],
+	waitingSync = L["|cffffffff%d|r/|cffffffff%d|r mail remaining - waiting for the next mailbox refresh..."],
+	soon = L["|cffffffff%d|r/|cffffffff%d|r mail remaining - everything will be opened soon..."],
 };
 
 function mod:UpdateTimer()
@@ -739,9 +740,9 @@
 	opening = openingStatus;
 	
 	if openingStatus then
-		self.btnOpenAll:SetText("Opening...");
+		self.btnOpenAll:SetText(L["Opening..."]);
 	else
-		self.btnOpenAll:SetText("Open all");
+		self.btnOpenAll:SetText(L["Open all"]);
 	end
 end
 
@@ -749,30 +750,30 @@
 	local configGroup = {
 		order = 300,
 		type = "group",
-		name = "Open All",
-		desc = "Change open all settings.",
+		name = L["Open All"],
+		desc = L["Change open all settings."],
 		args = {
 			filters = {
 				order = 10,
 				type = "group",
 				inline = true,
-				name = "Filters",
+				name = L["Filters"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "Toggle which mail the opener should autoloot.",
+						name = L["Toggle which mail the opener should autoloot."],
 					},
 					AHHeader = {
 						order = 15,
 						type = "header",
-						name = "Auction House Mail",
+						name = L["Auction House Mail"],
 					},
 					canceled = {
 						order = 20,
 						type = "toggle",
-						name = "Open all |cfffed000auction canceled|r mail",
-						desc = "Automatically loot all auction canceled mail from the auction house.",
+						name = L["Open all |cfffed000auction canceled|r mail"],
+						desc = L["Automatically loot all auction canceled mail from the auction house."],
 						set = function(i, v) self.db.profile.filter.AH.canceled = v; end,
 						get = function() return self.db.profile.filter.AH.canceled; end,
 						width = "double",
@@ -780,8 +781,8 @@
 					expired = {
 						order = 21,
 						type = "toggle",
-						name = "Open all |cfffed000auction expired|r mail",
-						desc = "Automatically loot all auction canceled mail from the auction house.",
+						name = L["Open all |cfffed000auction expired|r mail"],
+						desc = L["Automatically loot all auction expired mail from the auction house."],
 						set = function(i, v) self.db.profile.filter.AH.expired = v; end,
 						get = function() return self.db.profile.filter.AH.expired; end,
 						width = "double",
@@ -789,8 +790,8 @@
 					outbid = {
 						order = 22,
 						type = "toggle",
-						name = "Open all |cfffed000outbid on|r mail",
-						desc = "Automatically loot all auction outbid mail from the auction house.",
+						name = L["Open all |cfffed000outbid on|r mail"],
+						desc = L["Automatically loot all auction outbid mail from the auction house."],
 						set = function(i, v) self.db.profile.filter.AH.outbid = v; end,
 						get = function() return self.db.profile.filter.AH.outbid; end,
 						width = "double",
@@ -798,8 +799,8 @@
 					success = {
 						order = 23,
 						type = "toggle",
-						name = "Open all |cfffed000auction successful|r mail",
-						desc = "Automatically loot all auction successful mail from the auction house.",
+						name = L["Open all |cfffed000auction successful|r mail"],
+						desc = L["Automatically loot all auction successful mail from the auction house."],
 						set = function(i, v) self.db.profile.filter.AH.success = v; end,
 						get = function() return self.db.profile.filter.AH.success; end,
 						width = "double",
@@ -807,8 +808,8 @@
 					won = {
 						order = 24,
 						type = "toggle",
-						name = "Open all |cfffed000auction won|r mail",
-						desc = "Automatically loot all auction won mail from the auction house.",
+						name = L["Open all |cfffed000auction won|r mail"],
+						desc = L["Automatically loot all auction won mail from the auction house."],
 						set = function(i, v) self.db.profile.filter.AH.won = v; end,
 						get = function() return self.db.profile.filter.AH.won; end,
 						width = "double",
@@ -816,13 +817,13 @@
 					normalHeader = {
 						order = 30,
 						type = "header",
-						name = "Remaining Mail",
+						name = L["Remaining Mail"],
 					},
 					normalAttachments = {
 						order = 40,
 						type = "toggle",
-						name = "Normal mail with |cfffed000attachments|r",
-						desc = "Automatically loot all normal mail containing attachments (CoDs and Blizzard mail will be skipped).",
+						name = L["Normal mail with |cfffed000attachments|r"],
+						desc = L["Automatically loot all normal mail containing attachments (CoDs and Blizzard mail will be skipped)."],
 						set = function(i, v) self.db.profile.filter.normalAttachments = v; end,
 						get = function() return self.db.profile.filter.normalAttachments; end,
 						width = "double",
@@ -830,8 +831,8 @@
 					normalMoney = {
 						order = 50,
 						type = "toggle",
-						name = "Normal mail with |cfffed000gold|r",
-						desc = "Automatically loot all normal mail containing gold (CoDs and Blizzard mail will be skipped).",
+						name = L["Normal mail with |cfffed000gold|r"],
+						desc = L["Automatically loot all normal mail containing gold (CoDs and Blizzard mail will be skipped)."],
 						set = function(i, v) self.db.profile.filter.normalMoney = v; end,
 						get = function() return self.db.profile.filter.normalMoney; end,
 						width = "double",
@@ -839,8 +840,8 @@
 					allowShiftClick = {
 						order = 60,
 						type = "toggle",
-						name = "Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r, regardless of the above filters.",
-						desc = "Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r with attachments, temporarily overriding all filters.",
+						name = L["Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r, regardless of the above filters."],
+						desc = L["Allow shift-clicking of the |cfffed000Open All|r button to autoloot |cfffed000everything|r with attachments, temporarily overriding all filters."],
 						set = function(i, v) self.db.profile.filter.allowShiftClick = v; end,
 						get = function() return self.db.profile.filter.allowShiftClick; end,
 						width = "full",
@@ -852,21 +853,21 @@
 				order = 20,
 				type = "group",
 				inline = true,
-				name = "Opening Interval",
+				name = L["Opening Interval"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
 						name = function()
-							local defaultString = "The default behaviour for opening mail is to only do so right after new mail was received from the server. If you close the mailbox or your inventory is full before everything is opened you will have to click the open all button manually or wait for a next mailbox refresh.\n\n";
+							local defaultString = L["The default behavior for opening mail is to only do so right after new mail was received from the server. If you close the mailbox or your inventory is full before everything is opened you will have to click the open all button manually or wait for a next mailbox refresh."] .. "\n\n";
 							
 							local currentSettings = "";
 							if MailOpener.db.profile.general.continueOpening then
-								currentSettings = currentSettings .. "Mail Opener will |cff00ff00continue|r to attempt to open the remaining mail every |cfffed000" .. MailOpener.db.profile.general.waitTime .. " seconds|r. ";
+								currentSettings = currentSettings .. L["Mail Opener will |cff00ff00continue|r to attempt to open the remaining mail every |cfffed000%d seconds|r."]:format(MailOpener.db.profile.general.waitTime) .. " ";
 							else
-								currentSettings = currentSettings .. "Mail Opener will |cffff0000not|r continue to attempt to open the remaining mail and will only start opening when new mail has just been received from the server. ";
+								currentSettings = currentSettings .. L["Mail Opener will |cffff0000not|r continue to attempt to open the remaining mail and will only start opening when new mail has just been received from the server."] .. " ";
 							end
-							currentSettings = currentSettings .. "The first batch after each server refresh will be opened after waiting |cfffed000" .. MailOpener.db.profile.general.initialDelay .. " seconds|r.";
+							currentSettings = currentSettings .. L["The first batch after each server refresh will be opened after waiting |cfffed000%d seconds|r."]:format(MailOpener.db.profile.general.initialDelay);
 							return defaultString .. currentSettings;
 						end,
 					},
@@ -878,8 +879,8 @@
 					continueOpening = {
 						order = 20,
 						type = "toggle",
-						name = "Continue opening mail",
-						desc = "Continue opening mail at the interval set below, even if the mailbox wasn't refreshed recently.",
+						name = L["Continue opening mail"],
+						desc = L["Continue opening mail at the interval set below, even if the mailbox wasn't refreshed recently."],
 						width = "full",
 						get =  function() return MailOpener.db.profile.general.continueOpening; end,
 						set = function(i, v) MailOpener.db.profile.general.continueOpening = v; end,
@@ -891,8 +892,8 @@
 						min = 0.5,
 						max = 60,
 						step = 0.5,
-						name = "Continued Mail Opening Interval",
-						desc = "Change the interval at which Mail Opener tries to continue opening mail after opening the mailbox. Please note that this setting does not reduce the game's normal 60 seconds wait time for mail.\n\nThe default value is 5 seconds.",
+						name = L["Continued Mail Opening Interval"],
+						desc = L["Change the interval at which Mail Opener tries to continue opening mail after opening the mailbox. Please note that this setting does not reduce the game's normal 60 seconds wait time for mail.\n\nThe default value is 5 seconds."],
 						get = function() return MailOpener.db.profile.general.waitTime; end,
 						set = function(i, v) MailOpener.db.profile.general.waitTime = v; end,
 						disabled = function() return (not MailOpener.db.profile.general.continueOpening); end,
@@ -904,8 +905,8 @@
 						min = 0.5,
 						max = 60,
 						step = 0.5,
-						name = "Initial Mail Opening Delay",
-						desc = "Change the delay before Mail Opener tries opening mail after opening the mailbox or new mail has been received from the server.\n\nThe default value is 0.5 seconds.",
+						name = L["Initial Mail Opening Delay"],
+						desc = L["Change the delay before Mail Opener tries opening mail after opening the mailbox or new mail has been received from the server.\n\nThe default value is 0.5 seconds."],
 						get = function() return MailOpener.db.profile.general.initialDelay; end,
 						set = function(i, v) MailOpener.db.profile.general.initialDelay = v; end,
 					},
@@ -915,12 +916,12 @@
 				order = 30,
 				type = "group",
 				inline = true,
-				name = "Keep Free Space",
+				name = L["Keep Free Space"],
 				args = {
 					description = {
 						order = 10,
 						type = "description",
-						name = "You can set an amount of bag space you wish to reserve when opening mail. Mail with a higher amount of attachments than available space will be skipped completely with this option set above 0.",
+						name = L["You can set an amount of bag space you wish to reserve when opening mail. Mail with a higher amount of attachments than available space will be skipped completely with this option set above 0."],
 					},
 					header = {
 						order = 15,
@@ -934,8 +935,8 @@
 						max = 100,
 						step = 1,
 						width = "double",
-						name = "Keep free space",
-						desc = "Change the amount of space to reserve for other things when opening mail. If this option is set higher than 0, mail with a higher amount of attachments than available space will be skipped completely.\n\nE.g. If this is set to 1 and you have a total of 12 slots left then any mail with 12 attachments will be skipped while one with 11 attachments would be opened.",
+						name = L["Keep free space"],
+						desc = L["Change the amount of space to reserve for other things when opening mail. If this option is set higher than 0, mail with a higher amount of attachments than available space will be skipped completely.\n\nE.g. If this is set to 1 and you have a total of 12 slots left then any mail with 12 attachments will be skipped while one with 11 attachments would be opened."],
 						set = function(i, v) self.db.profile.keepFreeSpace = v; end,
 						get = function() return self.db.profile.keepFreeSpace; end,
 					},
@@ -950,7 +951,7 @@
 					description = {
 						order = 10,
 						type = "description",
-						name = "Change the speed at which mail is opened. You should set the opening speed to the lowest latency you have in a city or experiment with setting it to the minimum.",
+						name = L["Change the speed at which mail is opened. You should set the opening speed to the lowest latency you have in a city or experiment with setting it to the minimum."],
 					},
 					header = {
 						order = 15,
@@ -964,8 +965,8 @@
 						max = 2500,
 						step = 5,
 						width = "double",
-						name = "Open single mail interval",
-						desc = "Change the mail opening speed (in microseconds) for each mail. Lower may not always be faster.",
+						name = L["Open single mail interval"],
+						desc = L["Change the mail opening speed (in microseconds) for each mail. Lower may not always be faster."],
 						get = function() return ( self.db.profile.speed * 1000 ); end,
 						set = function(i, v) self.db.profile.speed = ( v / 1000 ); end,
 					},
@@ -978,5 +979,5 @@
 end
 
 function mod:Debug(t)
-	return MailOpener:Debug("|cff00ff00OpenAll|r:" .. t);
+	return MailOpener:Debug(("|cff00ff00OpenAll|r:%s"):format(t));
 end
\ No newline at end of file