mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-14 20:54:16 +01:00
Merge pull request #2315 from Haselnussbomber/imgui-bindings-fixes
[imgui-bindings] Fixes and removals
This commit is contained in:
commit
6efbb71790
21 changed files with 41 additions and 145 deletions
|
|
@ -634,25 +634,11 @@ public static partial class ImGuiHelpers
|
|||
.ToArray();
|
||||
|
||||
/// <summary>
|
||||
/// Determines whether <paramref name="ptr"/> is empty.
|
||||
/// Determines whether <paramref name="ptr"/> is not empty and loaded.
|
||||
/// </summary>
|
||||
/// <param name="ptr">The pointer.</param>
|
||||
/// <returns>Whether it is empty.</returns>
|
||||
public static unsafe bool IsNull(this ImFontPtr ptr) => ptr.Handle == null;
|
||||
|
||||
/// <summary>
|
||||
/// Determines whether <paramref name="ptr"/> is empty.
|
||||
/// </summary>
|
||||
/// <param name="ptr">The pointer.</param>
|
||||
/// <returns>Whether it is empty.</returns>
|
||||
public static unsafe bool IsNotNullAndLoaded(this ImFontPtr ptr) => ptr.Handle != null && ptr.IsLoaded();
|
||||
|
||||
/// <summary>
|
||||
/// Determines whether <paramref name="ptr"/> is empty.
|
||||
/// </summary>
|
||||
/// <param name="ptr">The pointer.</param>
|
||||
/// <returns>Whether it is empty.</returns>
|
||||
public static unsafe bool IsNull(this ImFontAtlasPtr ptr) => ptr.Handle == null;
|
||||
/// <returns>Whether it is not null and loaded.</returns>
|
||||
public static unsafe bool IsNotNullAndLoaded(this ImFontPtr ptr) => !ptr.IsNull && ptr.IsLoaded();
|
||||
|
||||
/// <summary>
|
||||
/// If <paramref name="self"/> is default, then returns <paramref name="other"/>.
|
||||
|
|
@ -661,7 +647,7 @@ public static partial class ImGuiHelpers
|
|||
/// <param name="other">The other.</param>
|
||||
/// <returns><paramref name="self"/> if it is not default; otherwise, <paramref name="other"/>.</returns>
|
||||
public static unsafe ImFontPtr OrElse(this ImFontPtr self, ImFontPtr other) =>
|
||||
self.Handle is null ? other : self;
|
||||
self.IsNull ? other : self;
|
||||
|
||||
/// <summary>
|
||||
/// Mark 4K page as used, after adding a codepoint to a font.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue