Dispose MapPreviews and map packages.

This commit is contained in:
Paul Chote
2016-02-26 08:46:07 +00:00
parent b5f792b997
commit bee3eb2c0a
2 changed files with 13 additions and 1 deletions

View File

@@ -269,6 +269,9 @@ namespace OpenRA
return;
}
foreach (var p in previews.Values)
p.Dispose();
// We need to let the loader thread exit before we can dispose our sheet builder.
// Ideally we should dispose our resources before returning, but we don't to block waiting on the loader thread to exit.
// Instead, we'll queue disposal to be run once it has exited.