debug: Add print to QuestLogTitleButton_OnClick hook

This commit is contained in:
Xurkon
2026-03-20 22:49:03 -05:00
parent 7fb8155af1
commit 5916be505f
2 changed files with 5 additions and 1 deletions
+4 -1
View File
@@ -19,6 +19,7 @@ function Hooks:HookQuestLogTitle()
-- FIX: Added InCombatLockdown guard to prevent tainting secure execution paths.
-- This hook can be called during combat if the player interacts with the quest log
-- while in combat, which may cause taint that propagates to protected functions.
print("[DEBUG] QuestLogTitleButton_OnClick hook! button=" .. tostring(button) .. " shift=" .. tostring(IsShiftKeyDown()))
if InCombatLockdown() then return end
if (not self) or self.isHeader then
return
@@ -46,7 +47,9 @@ function Hooks:HookQuestLogTitle()
-- For all other clicks (including tracking/untracking), use the original function
-- only call Questie's tracker if we actually want to fix this quest (normal quests already call AQW_insert)
if Questie.db.profile.trackerEnabled and GetNumQuestLeaderBoards(questLogLineIndex) == 0 then
-- Only handle tracking on shift-click for "Talk to" quests (no objectives)
if Questie.db.profile.trackerEnabled and GetNumQuestLeaderBoards(questLogLineIndex) == 0 and IsShiftKeyDown() then
print("[DEBUG] Hook tracking condition met for questId=", questId)
local _, _, _, _, _, _, _, questId = GetQuestLogTitle(questLogLineIndex)
if questId and questId > 0 then
if Questie.db.char.TrackedQuests[questId] or (Questie.db.profile.autoTrackQuests and (not Questie.db.char.AutoUntrackedQuests[questId])) then
+1
View File
@@ -158,6 +158,7 @@ function TrackerLinePool.Initialize(questFrame)
-- TEST: Always capture clicks to debug
line:SetScript("OnClick", function(self, button)
print("[DEBUG] TEST_OnClick FIRED! button=" .. tostring(button) .. " lineName=" .. self:GetName())
Questie:Debug(Questie.DEBUG_DEVELOP, "[TrackerLinePool:TEST_OnClick] button:", button, "Shift:", IsShiftKeyDown())
end)