Add keybind to toggle using the focus target. Add esES localization from Ben (Aesyl - US Tanaris) and koKR from Sayclub.

This commit is contained in:
Xinhuan
2008-10-15 14:50:57 +08:00
parent 04a13912d3
commit 612b240b39
8 changed files with 545 additions and 10 deletions
+12 -9
View File
@@ -24,6 +24,7 @@ _G["Omen"] = Omen
-- Keybinding globals
BINDING_HEADER_OMEN = "Omen"
BINDING_NAME_OMENTOGGLE = L["Toggle Omen"]
BINDING_NAME_OMENTOGGLEFOCUS = L["Toggle Focus"]
-----------------------------------------------------------------------------
@@ -712,6 +713,16 @@ function Omen:UpdateGrips()
end
end
function Omen:ToggleFocus()
db.UseFocus = not db.UseFocus
if db.UseFocus then
Omen:RegisterEvent("UNIT_TARGET")
else
Omen:UnregisterEvent("UNIT_TARGET")
end
Omen:UpdateBars()
end
-----------------------------------------------------------------------------
-- Omen warnings
@@ -1447,15 +1458,7 @@ do
UIDropDownMenu_AddButton(info, level)
info.text = "Use Focus Target"
info.func = function()
db.UseFocus = not db.UseFocus
if db.UseFocus then
Omen:RegisterEvent("UNIT_TARGET")
else
Omen:UnregisterEvent("UNIT_TARGET")
end
Omen:UpdateBars()
end
info.func = function() Omen:ToggleFocus() end
info.checked = db.UseFocus
UIDropDownMenu_AddButton(info, level)