local function TalentQuery() --send request for talent info |
if CanInspect("mouseover") and db.showTalentText then |
if UnitName("mouseover") ~= player and UnitLevel("mouseover") > 9 then |
local talentline = nil |
local talentline = false |
for i=1, tt:NumLines() do |
local left, leftText |
left = _G["GameTooltipTextLeft"..i] |
leftText = left:GetText() |
if leftText == "Talents:" then |
talentline = 1 |
if leftText == specializationText then |
talentline = true |
break |
end |
end |
if not talentline then |
--we'll leave this in until the default UI gets all the kinks out |
if InspectFrame and InspectFrame:IsShown() then --to not step on default UI's toes |
tt:AddDoubleLine("Talents:", "Inspect Frame is open", nil,nil,nil, 1,0,0) |
tt:AddDoubleLine(specializationText, "Inspect Frame is open", nil,nil,nil, 1,0,0) |
elseif Examiner and Examiner:IsShown() then --same thing with Examiner |
tt:AddDoubleLine("Talents:", "Examiner frame is open", nil,nil,nil, 1,0,0) |
tt:AddDoubleLine(specializationText, "Examiner frame is open", nil,nil,nil, 1,0,0) |
else |
talentsGUID = UnitGUID("mouseover") |
NotifyInspect("mouseover") |
TipTop:RegisterEvent("INSPECT_READY") |
tt:AddDoubleLine("Specialization:", "...") --adds the Talents line with a placeholder for info |
tt:AddDoubleLine(specializationText, "...") --adds the Talents line with a placeholder for info |
end |
tt:Show() |
end |