Quantcast

Default mana display disabled

Scott Sibley [09-11-10 - 23:13]
Default mana display disabled
Filename
Display.lua
config.lua
diff --git a/Display.lua b/Display.lua
index eaf3e44..06f2463 100644
--- a/Display.lua
+++ b/Display.lua
@@ -120,7 +120,7 @@ function mod:RebuildOpts()
 		name = "Add Display",
 		type = "input",
 		set = function(info, v)
-			self.db.profile.config["display_" .. v] = {name = v, layouts = {}, widgets = {}, point = {"TOPLEFT", "UiParent", "BOTTOMLEFT", 0, -50}}
+			self.db.profile.config["display_" .. v] = {name = v, layouts = {}, widgets = {}, point = {"TOPLEFT", "UiParent", "BOTTOMLEFT", 0, -50}, parent="UIParent"}
 			LCD4WoW:RebuildOpts()
 		end,
 		order = 1
@@ -313,6 +313,13 @@ function mod:RebuildOpts()
 								get = function() return tostring(db.point[5] or 0) end,
 								set = function(info, v) db.point[5] = tonumber(v); clearHistograms();createHistograms() end,
 								order = 4
+							},
+							parent = {
+								name = "Parent",
+								type = "input",
+								get = function() return db.parent or "UIParent" end,
+								set = function(info, v) db.parent = v end,
+								order = 5
 							}
 						},
 						order = 7
diff --git a/config.lua b/config.lua
index 7ee6165..5669b09 100644
--- a/config.lua
+++ b/config.lua
@@ -66,12 +66,12 @@ LCD4WoW.config = {
 	},
 	["display_mana"] = {
 		["addon"] = "LCD4WoW",
-		["enabled"] = true,
+		["enabled"] = false,
 		["driver"] = "character",
 		["pixel"] = 1,
 		["layers"] = 1,
 		["rows"] = 1,
-		["cols"] = 9,
+		["cols"] = 14,
 		["layouts"] = {"layout_mana"},
 		["widgets"] = {},
 		["point"] = {"TOPLEFT", "GameTooltip", "BOTTOMLEFT", 0, -130},
@@ -196,9 +196,9 @@ Update()
 	},
 	["widget_text_mana"] = {
 		type = "text",
-		value = 'return "Rage: " .. (UnitMana("player") / UnitManaMax("player") * 100)',
-		align = ALIGN_LEFT,
-		cols = 9,
+		value = 'return "Power: " .. (UnitMana("player") / UnitManaMax("player") * 100) .. "%"',
+		align = ALIGN_RIGHT,
+		cols = 14,
 		update = 1000,
 		dontRtrim = true
 	},