mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
chore: throw if TextureManagerTextureWrap is used beyond disposal
This commit is contained in:
parent
dc95d7e8de
commit
39e389080c
1 changed files with 3 additions and 1 deletions
|
|
@ -574,7 +574,9 @@ internal class TextureManagerTextureWrap : IDalamudTextureWrap
|
|||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public IntPtr ImGuiHandle => this.manager.GetInfo(this.path).Wrap!.ImGuiHandle;
|
||||
public IntPtr ImGuiHandle => !this.IsDisposed ?
|
||||
this.manager.GetInfo(this.path).Wrap!.ImGuiHandle :
|
||||
throw new InvalidOperationException("Texture already disposed. You may not render it.");
|
||||
|
||||
/// <inheritdoc/>
|
||||
public int Width { get; private set; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue