From 492bdc0b5e4f85d11b67663bfefea07e4bd4a6e4 Mon Sep 17 00:00:00 2001 From: shagu Date: Sat, 23 Nov 2024 23:59:03 +0100 Subject: [PATCH] chat: set max lines before history is added --- modules/chat.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/chat.lua b/modules/chat.lua index 317bcc3d..a26e2491 100644 --- a/modules/chat.lua +++ b/modules/chat.lua @@ -359,10 +359,6 @@ pfUI:RegisterModule("chat", "vanilla:tbc", function () frame:SetFading(false) end - if C.chat.global.maxlines ~= "128" then - frame:SetMaxLines(tonumber(C.chat.global.maxlines) or 128) - end - if i == 3 and C.chat.right.enable == "1" then -- Loot & Spam local bottompadding = pfUI.panel and pfUI.panel.right:IsShown() and not pfUI_config.position["pfPanelRight"] and panelheight or default_border @@ -818,6 +814,10 @@ pfUI:RegisterModule("chat", "vanilla:tbc", function () end for i=1,NUM_CHAT_WINDOWS do + if C.chat.global.maxlines ~= "128" then + _G["ChatFrame"..i]:SetMaxLines(tonumber(C.chat.global.maxlines) or 128) + end + if not _G["ChatFrame"..i].HookAddMessage then if C.chat.text.history == "1" then -- write history to chat