From ee4952078cdc66fc122df72323e2a48aa9900e98 Mon Sep 17 00:00:00 2001 From: Scott Sibley Date: Wed, 20 Oct 2010 22:27:45 +0000 Subject: [PATCH] Bug fix. Text widgets should work again. --- Modules/Texts/Texts.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Modules/Texts/Texts.lua b/Modules/Texts/Texts.lua index 264f856..ccf19d7 100644 --- a/Modules/Texts/Texts.lua +++ b/Modules/Texts/Texts.lua @@ -57,12 +57,12 @@ local defaultWidgets = { [1] = { name = "Name", enabled = true, - frameName = "StarTipTextName", value = [[ if not UnitExists(unit) then return end return '--' .. select(1, UnitName(unit)) .. '--' ]], color = [[ +_G.StarTip:Print(unit) if UnitIsPlayer(unit) then return ClassColor(unit) else @@ -327,13 +327,13 @@ local new, del do local pool = {} local i = 0 - function new(name, parent, background) + function new(background) local text = next(pool) if text then pool[text] = nil else - local frame = CreateFrame("Frame", name, parent) + local frame = CreateFrame("Frame") frame:SetParent(UIParent) if background then frame:SetBackdrop({bgFile = "Interface\\Tooltips\\UI-Tooltip-Background", @@ -406,7 +406,7 @@ function createTexts() end local widget = mod.texts[v] if not widget then - local text = new(v.frameName, v.parent, v.background) + local text = new(v.background) widget = WidgetText:New(mod.core, v.name, v, v.row or 0, v.col or 0, v.layer or 0, StarTip.db.profile.errorLevel, updateText) text:ClearAllPoints() text:SetParent("UIParent") -- 1.7.9.5