performance: tooltip memory usage

This commit is contained in:
Salikh Gurgenidze
2026-01-24 02:47:27 +04:00
parent 06615cf96e
commit 5376f0f0ef
6 changed files with 35 additions and 45 deletions
+5 -6
View File
@@ -127,12 +127,9 @@ local GEM_PATTERNS = {
--===========================================================================
-- UTILITY FUNCTIONS
-- Uses shared tooltip from Utils module
--===========================================================================
-- Tooltip for scanning item properties
local scanTooltip = CreateFrame("GameTooltip", "Guda_SortScanTooltip", nil, "GameTooltipTemplate")
scanTooltip:SetOwner(WorldFrame, "ANCHOR_NONE")
-- Property cache to prevent race conditions during rapid moves
local propertyCache = {}
@@ -166,13 +163,15 @@ local function GetItemProperties(bagID, slotID, itemLink)
end
if bagID and slotID then
-- Use shared tooltip from Utils module
local scanTooltip, tooltipName = addon.Modules.Utils:GetScanTooltip()
scanTooltip:ClearLines()
scanTooltip:SetBagItem(bagID, slotID)
local numLines = scanTooltip:NumLines()
if numLines and numLines > 0 then
for i = 1, numLines do
local line = getglobal("Guda_SortScanTooltipTextLeft" .. i)
local line = getglobal(tooltipName .. "TextLeft" .. i)
if line then
local text = line:GetText()
if text then