Support borderless panel types.

This commit is contained in:
Paul Chote
2014-03-23 17:03:58 +13:00
parent 31991c3679
commit aa77536e96
2 changed files with 33 additions and 40 deletions

View File

@@ -79,12 +79,8 @@ namespace OpenRA.Graphics
return cachedSprites[collection][image];
MappedImage mi;
try { mi = collections[collection].regions[image]; }
catch (KeyNotFoundException)
{
throw new InvalidOperationException(
"Collection `{0}` does not have an image `{1}`".F(collection, image));
}
if (!collections[collection].regions.TryGetValue(image, out mi))
return null;
// Cached sheet
Sheet sheet;