From 03ae1ec2fc555aa9b59f9e3e2f3c564a1a5706dc Mon Sep 17 00:00:00 2001 From: Anna Clemens Date: Wed, 29 Dec 2021 22:00:07 -0500 Subject: [PATCH] fix: don't always close normal tooltips --- ChatTwo/PayloadHandler.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ChatTwo/PayloadHandler.cs b/ChatTwo/PayloadHandler.cs index 37d3531..251514a 100755 --- a/ChatTwo/PayloadHandler.cs +++ b/ChatTwo/PayloadHandler.cs @@ -16,6 +16,7 @@ internal sealed class PayloadHandler { private HashSet Popups { get; set; } = new(); + private bool _handleTooltips; private uint _hoveredItem; private uint _hoverCounter; private uint _lastHoverCounter; @@ -44,10 +45,11 @@ internal sealed class PayloadHandler { this.Popups = newPopups; - if (++this._hoverCounter - this._lastHoverCounter > 1) { + if (this._handleTooltips && ++this._hoverCounter - this._lastHoverCounter > 1) { this.Ui.Plugin.Functions.CloseItemTooltip(); this._hoveredItem = 0; this._hoverCounter = this._lastHoverCounter = 0; + this._handleTooltips = false; } } @@ -74,6 +76,7 @@ internal sealed class PayloadHandler { if (this.Ui.Plugin.Config.NativeItemTooltips) { this.Ui.Plugin.Functions.OpenItemTooltip(item.ItemId); + this._handleTooltips = true; if (this._hoveredItem != item.ItemId) { this._hoveredItem = item.ItemId; this._hoverCounter = this._lastHoverCounter = 0;