mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-15 05:04:15 +01:00
feat: prevent AgentHud::OpenSystemMenu when any ImGui window has focus
This commit is contained in:
parent
3f927ee7f0
commit
9228fac4ee
2 changed files with 4 additions and 3 deletions
|
|
@ -76,7 +76,7 @@ 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);
|
||||
// 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)
|
||||
|
|
@ -87,6 +87,9 @@ namespace Dalamud.Game.Internal
|
|||
|
||||
private void AgentHudOpenSystemMenuDetour(void* thisPtr, AtkValue* atkValueArgs, uint menuSize)
|
||||
{
|
||||
if (WindowSystem.HasAnyWindowSystemFocus)
|
||||
return;
|
||||
|
||||
var configuration = Service<DalamudConfiguration>.Get();
|
||||
|
||||
if (!configuration.DoButtonsSystemMenu)
|
||||
|
|
|
|||
|
|
@ -2,8 +2,6 @@ using System.Numerics;
|
|||
|
||||
using Dalamud.Game.ClientState.Keys;
|
||||
using ImGuiNET;
|
||||
using Microsoft.CodeAnalysis;
|
||||
using Serilog;
|
||||
|
||||
namespace Dalamud.Interface.Windowing
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue