mirror of
https://github.com/Caraxi/mare.client.git
synced 2025-12-13 15:44:14 +01:00
do not use actionqueue for redraws
This commit is contained in:
parent
e5698c4c0c
commit
849ba51ce2
2 changed files with 12 additions and 2 deletions
|
|
@ -605,12 +605,12 @@ public sealed class IpcManager : DisposableMediatorSubscriberBase
|
||||||
|
|
||||||
_penumbraRedrawRequests[obj.Address] = !fireAndForget;
|
_penumbraRedrawRequests[obj.Address] = !fireAndForget;
|
||||||
|
|
||||||
ActionQueue.Enqueue(action);
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (!fireAndForget)
|
if (!fireAndForget)
|
||||||
{
|
{
|
||||||
|
await _dalamudUtil.RunOnFrameworkThread(action);
|
||||||
|
|
||||||
var disposeToken = _disposalCts.Token;
|
var disposeToken = _disposalCts.Token;
|
||||||
var combinedToken = CancellationTokenSource.CreateLinkedTokenSource(disposeToken, token).Token;
|
var combinedToken = CancellationTokenSource.CreateLinkedTokenSource(disposeToken, token).Token;
|
||||||
|
|
||||||
|
|
@ -619,6 +619,10 @@ public sealed class IpcManager : DisposableMediatorSubscriberBase
|
||||||
if (!combinedToken.IsCancellationRequested)
|
if (!combinedToken.IsCancellationRequested)
|
||||||
await _dalamudUtil.WaitWhileCharacterIsDrawing(logger, obj, applicationId, 30000, combinedToken).ConfigureAwait(false);
|
await _dalamudUtil.WaitWhileCharacterIsDrawing(logger, obj, applicationId, 30000, combinedToken).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
_ = _dalamudUtil.RunOnFrameworkThread(action);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
finally
|
finally
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -209,6 +209,12 @@ public class ServerConfigurationManager
|
||||||
|
|
||||||
internal void DeleteServer(ServerStorage selectedServer)
|
internal void DeleteServer(ServerStorage selectedServer)
|
||||||
{
|
{
|
||||||
|
if (Array.IndexOf(_configService.Current.ServerStorage.ToArray(), selectedServer) <
|
||||||
|
_configService.Current.CurrentServer)
|
||||||
|
{
|
||||||
|
_configService.Current.CurrentServer--;
|
||||||
|
}
|
||||||
|
|
||||||
_configService.Current.ServerStorage.Remove(selectedServer);
|
_configService.Current.ServerStorage.Remove(selectedServer);
|
||||||
Save();
|
Save();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue