mirror of
https://github.com/MaaAssistantArknights/MaaAssistantArknights.git
synced 2026-07-18 10:10:45 +08:00
fix.修复c#退出时不释放asst实例的问题
https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues/855
This commit is contained in:
@@ -74,6 +74,14 @@ namespace MeoAsstGui
|
||||
_callback = CallbackFunction;
|
||||
}
|
||||
|
||||
~AsstProxy()
|
||||
{
|
||||
if (_handle != IntPtr.Zero)
|
||||
{
|
||||
AsstDestroy();
|
||||
}
|
||||
}
|
||||
|
||||
public void Init()
|
||||
{
|
||||
bool loaded = AsstLoadResource(System.IO.Directory.GetCurrentDirectory());
|
||||
@@ -809,6 +817,11 @@ namespace MeoAsstGui
|
||||
{
|
||||
return AsstStop(_handle);
|
||||
}
|
||||
|
||||
public void AsstDestroy()
|
||||
{
|
||||
AsstDestroy(_handle);
|
||||
}
|
||||
}
|
||||
|
||||
public enum AsstMsg
|
||||
|
||||
Reference in New Issue
Block a user