Add Frame Strata and Clamp To Screen options.

This commit is contained in:
Xinhuan
2008-11-01 04:45:28 +08:00
parent e44f5c6f91
commit 10b3cf44a2
8 changed files with 83 additions and 19 deletions
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = "Sichtbarkeit"
L["Controls the transparency of the main Omen window."] = "Kontrolliert die Sichtbarkeit des Omen Hauptfensters"
L["Scale"] = "Skalierung"
L["Controls the scaling of the main Omen window."] = "Kontrolliert die Skalierung des Omen Hauptfensters"
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = "Lässt Omen zusätzlich den Fokus und das Fokusziel vor dem Ziel und dem Ziel des Ziels für die Bedrohungsanzeige überprüfen"
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = "Startet den Omen Testmodus um das Einstellen der Anzeige zu vereinfachen"
L["Collapse to show a minimum number of bars"] = "Zusammenklappen um nur eine minimale Anzahl an Balken zu zeigen"
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = true
L["Controls the transparency of the main Omen window."] = true
L["Scale"] = true
L["Controls the scaling of the main Omen window."] = true
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = true
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = true
L["Collapse to show a minimum number of bars"] = true
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = "Transparence"
L["Controls the transparency of the main Omen window."] = "Contrôle la transparence de la fenêtre principale de Omen."
L["Scale"] = "Échelle"
L["Controls the scaling of the main Omen window."] = "Contrôle l'échelle de la fenêtre principale de Omen."
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = "Demande à Omen de vérifier également votre focalisation et la cible de votre focalisation (dans cet ordre) pour l'affichage de la menace."
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = "Demande à Omen d'entrer en mode de test afin que vous puissiez le configurer beaucoup plus facilement."
L["Collapse to show a minimum number of bars"] = "Réduit Omen afin de n'afficher qu'un nombre minimal de barres."
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = "투명도"
L["Controls the transparency of the main Omen window."] = "Omen 창의 투명도를 조절합니다."
L["Scale"] = "크기"
L["Controls the scaling of the main Omen window."] = "Omen 창의 크기를 조절합니다."
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = "Omen에 당신의 '대상'과 '대상의 대상'에 대한 위협을 표시하기 위해 추가로 당신의 '주시'와 '주시 대상'을 검사합니다."
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = "Omen을 쉽게 설정할 수 있도록 테스트 모드에 들어갑니다."
L["Collapse to show a minimum number of bars"] = "최소한의 바를 표시하기 위해 접기를 합니다."
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = "Прозрачность"
L["Controls the transparency of the main Omen window."] = "Настройка прозрачности главного окна Омена"
L["Scale"] = "Масштаб"
L["Controls the scaling of the main Omen window."] = "Настройка масштаба главного окна Омена"
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = "Омен выполняет дополнительную проверку вашего 'focus' и 'focustarget' на наличие угрозы для отображение её."
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = "Омен входит в режим тестирования, что позволит вам его настроить для более лучшего отображения данных."
L["Collapse to show a minimum number of bars"] = "Collapse to show a minimum number of bars"
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = "透明度"
L["Controls the transparency of the main Omen window."] = "控制 Omen 主窗口的透明度。"
L["Scale"] = "缩放"
L["Controls the scaling of the main Omen window."] = "控制 Omen 主窗口的尺寸。"
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = true
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = true
L["Collapse to show a minimum number of bars"] = "收起以显示最小数量的计量条"
+4
View File
@@ -33,6 +33,10 @@ L["Alpha"] = true
L["Controls the transparency of the main Omen window."] = "控制主視窗的透明度"
L["Scale"] = "縮放"
L["Controls the scaling of the main Omen window."] = "控制主視窗的尺寸"
L["Frame Strata"] = true
L["Controls the frame strata of the main Omen window. Default: MEDIUM"] = true
L["Clamp To Screen"] = true
L["Controls whether the main Omen window can be dragged offscreen"] = true
L["Tells Omen to additionally check your 'focus' and 'focustarget' before your 'target' and 'targettarget' in that order for threat display."] = true
L["Tells Omen to enter Test Mode so that you can configure Omen's display much more easily."] = true
L["Collapse to show a minimum number of bars"] = "收起以顯示最小數量的計量條"
+55 -19
View File
@@ -79,6 +79,8 @@ local defaults = {
VGrip2 = 115,
UseFocus = false,
IgnorePlayerPets = true,
FrameStrata = "3-MEDIUM",
ClampToScreen = true,
Background = {
Texture = "Blizzard Parchment",
BorderTexture = "Blizzard Dialog",
@@ -319,7 +321,6 @@ function Omen:CreateFrames()
self.Anchor:SetPoint("CENTER", UIParent, "CENTER")
self.Anchor:SetWidth(225)
self.Anchor:SetHeight(150)
self.Anchor:SetClampedToScreen(true)
self.Anchor:SetScript("OnHide", stopmoving)
-- Create Title
@@ -459,6 +460,8 @@ function Omen:PLAYER_LOGIN()
-- is loaded just before this event fires.
self:SetAnchors(true)
self.Anchor:SetAlpha(db.Alpha)
self.Anchor:SetFrameStrata(strsub(db.FrameStrata, 3))
self.Anchor:SetClampedToScreen(db.ClampToScreen)
self:UpdateBackdrop()
self:UpdateTitleBar()
self:UpdateGrips()
@@ -550,6 +553,8 @@ function Omen:OnProfileChanged(event, database, newProfileKey)
db = database.profile
self:SetAnchors(true)
self.Anchor:SetAlpha(db.Alpha)
self.Anchor:SetFrameStrata(strsub(db.FrameStrata, 3))
self.Anchor:SetClampedToScreen(db.ClampToScreen)
self:UpdateBackdrop()
self:UpdateTitleBar()
self:UpdateGrips()
@@ -1672,7 +1677,7 @@ local options = {
end,
},
Scale = {
order = 5,
order = 4,
name = L["Scale"],
desc = L["Controls the scaling of the main Omen window."],
type = "range",
@@ -1683,6 +1688,36 @@ local options = {
Omen:SetAnchors()
end,
},
FrameStrata = {
type = "select",
order = 5,
name = L["Frame Strata"],
desc = L["Controls the frame strata of the main Omen window. Default: MEDIUM"],
values = { -- A hack to sort them in the menu
["1-BACKGROUND"] = "BACKGROUND",
["2-LOW"] = "LOW",
["3-MEDIUM"] = "MEDIUM",
["4-HIGH"] = "HIGH",
["5-DIALOG"] = "DIALOG",
["6-FULLSCREEN"] = "FULLSCREEN",
["7-FULLSCREEN_DIALOG"] = "FULLSCREEN_DIALOG",
["8-TOOLTIP"] = "TOOLTIP",
},
set = function(info, value)
db.FrameStrata = value
Omen.Anchor:SetFrameStrata(strsub(value, 3))
end,
},
ClampToScreen = {
type = "toggle",
name = L["Clamp To Screen"],
desc = L["Controls whether the main Omen window can be dragged offscreen"],
order = 6,
set = function(info, value)
db.ClampToScreen = value
Omen.Anchor:SetFrameStrata(value)
end,
},
Locked = {
type = "toggle",
name = L["Lock Omen"],
@@ -1734,20 +1769,6 @@ local options = {
Omen:UpdateBars()
end,
},
Autocollapse = {
type = "toggle",
name = L["Autocollapse"],
desc = L["Collapse to show a minimum number of bars"],
order = 20,
set = function(info, value)
db.Autocollapse = value
Omen.Anchor:SetHeight(6*db.Bar.Height + 5*db.Bar.Spacing + Omen.Title:GetHeight() + 2*db.Background.BarInset)
Omen:SetAnchors()
Omen.BarList:Show()
Omen:UpdateVisible()
Omen:UpdateBars()
end,
},
AutocollapseGroup = {
type = "group",
name = L["Autocollapse Options"],
@@ -1760,8 +1781,23 @@ local options = {
Omen:UpdateBars()
end,
args = {
GrowUp = {
Autocollapse = {
type = "toggle",
name = L["Autocollapse"],
desc = L["Collapse to show a minimum number of bars"],
order = 1,
set = function(info, value)
db.Autocollapse = value
Omen.Anchor:SetHeight(6*db.Bar.Height + 5*db.Bar.Spacing + Omen.Title:GetHeight() + 2*db.Background.BarInset)
Omen:SetAnchors()
Omen.BarList:Show()
Omen:UpdateVisible()
Omen:UpdateBars()
end,
disabled = false,
},
GrowUp = {
order = 2,
type = "toggle",
name = L["Grow bars upwards"],
desc = L["Grow bars upwards"],
@@ -1771,13 +1807,13 @@ local options = {
end,
},
CollapseHide = {
order = 2,
order = 3,
type = "toggle",
name = L["Hide Omen on 0 bars"],
desc = L["Hide Omen entirely if it collapses to show 0 bars"],
},
NumBars = {
order = 3,
order = 4,
name = L["Max bars to show"],
desc = L["Max number of bars to show"],
type = "range",