mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-14 20:54:16 +01:00
fix: only allow pinning/clickthrough if the window is within the main viewport
This commit is contained in:
parent
f10a597566
commit
c03d6ff048
2 changed files with 30 additions and 6 deletions
|
|
@ -25,6 +25,13 @@ public static class ImGuiHelpers
|
|||
/// </summary>
|
||||
public static float GlobalScale { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Check if the current ImGui window is on the main viewport.
|
||||
/// Only valid within a window.
|
||||
/// </summary>
|
||||
/// <returns>Whether the window is on the main viewport.</returns>
|
||||
public static bool CheckIsWindowOnMainViewport() => MainViewport.ID == ImGui.GetWindowViewport().ID;
|
||||
|
||||
/// <summary>
|
||||
/// Gets a <see cref="Vector2"/> that is pre-scaled with the <see cref="GlobalScale"/> multiplier.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue