fix: always set IsFocused to false when closing a window

This commit is contained in:
goat 2021-09-02 17:31:19 +02:00
parent 395328eb17
commit 3f927ee7f0
No known key found for this signature in database
GPG key ID: F18F057873895461
4 changed files with 21 additions and 7 deletions

View file

@ -76,6 +76,8 @@ namespace Dalamud.Game.Internal
private IntPtr AtkUnitBaseReceiveGlobalEventDetour(AtkUnitBase* thisPtr, ushort cmd, uint a3, IntPtr a4, uint* a5)
{
Log.Information("{0}: cmd#{1} a3#{2} - HasAnyFocus:{3}", Marshal.PtrToStringAnsi(new IntPtr(thisPtr->Name)), cmd, a3, WindowSystem.HasAnyWindowSystemFocus);
// "Close Addon"
if (cmd == 12 && WindowSystem.HasAnyWindowSystemFocus)
return IntPtr.Zero;