mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-30 12:23:39 +01:00
Add ITextureProvider.CreateTextureFromSeString
This commit is contained in:
parent
d3bd5f1dce
commit
c19ea6ace3
19 changed files with 629 additions and 215 deletions
|
|
@ -238,12 +238,17 @@ internal abstract class FontHandle : IFontHandle
|
|||
}
|
||||
|
||||
/// <inheritdoc/>
|
||||
public Task<IFontHandle> WaitAsync()
|
||||
public Task<IFontHandle> WaitAsync() => this.WaitAsync(CancellationToken.None);
|
||||
|
||||
/// <inheritdoc/>
|
||||
public Task<IFontHandle> WaitAsync(CancellationToken cancellationToken)
|
||||
{
|
||||
if (this.Available)
|
||||
return Task.FromResult<IFontHandle>(this);
|
||||
|
||||
var tcs = new TaskCompletionSource<IFontHandle>(TaskCreationOptions.RunContinuationsAsynchronously);
|
||||
cancellationToken.Register(() => tcs.TrySetCanceled());
|
||||
|
||||
this.ImFontChanged += OnImFontChanged;
|
||||
this.Disposed += OnDisposed;
|
||||
if (this.Available)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue