Deactivation of buggy Splat custom icon implementation

This commit is contained in:
BONNEVILLE Geoffroy
2018-03-12 12:40:07 +01:00
parent fb0eab00c2
commit 7613629d87
3 changed files with 14 additions and 16 deletions

View File

@@ -80,11 +80,7 @@ namespace ModernKeePassLib
// MemoryStream ms = new MemoryStream(m_pbImageDataPng, false);
// m_imgOrg = Image.FromStream(ms);
// ms.Close();
#if ModernKeePassLib
try { m_imgOrg = GfxUtil.LoadImage(m_pbImageDataPng).GetAwaiter().GetResult(); }
#else
try { m_imgOrg = GfxUtil.LoadImage(m_pbImageDataPng); }
#endif
catch(Exception) { Debug.Assert(false); m_imgOrg = null; }
if(m_imgOrg != null)
@@ -121,13 +117,14 @@ namespace ModernKeePassLib
Image img;
if(m_dImageCache.TryGetValue(lID, out img)) return img;
#if ModernKeePassLib
img = GfxUtil.ScaleImage(m_pbImageDataPng, w, h).GetAwaiter().GetResult();
img = GfxUtil.ScaleImage(m_pbImageDataPng, w, h);
#else
img = GfxUtil.ScaleImage(m_imgOrg, w, h, ScaleTransformFlags.UIIcon);
#endif
m_dImageCache[lID] = img;
return img;
m_dImageCache[lID] = img;
return img;
}
#endif
}