示例#1
0
 private static string ExtractSupportedDevicesFromInfo(HexArchiveInfo info)
 {
     try
     {
         return(info.Binaries.Select(b => b.Device).Distinct().Aggregate((l, r) => $"{l}, {r}"));
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex);
         return(String.Empty);
     }
 }
示例#2
0
 private static void PopulateScreenshotBitmapsFromInfo(ZipArchive zipArchive, HexArchiveInfo hexArchiveInfo)
 {
     foreach (var screenshot in hexArchiveInfo.Screenshots)
     {
         var bitmapEntry = zipArchive.Entries.FirstOrDefault(n => n.Key == screenshot.Filename);
         if (bitmapEntry != null)
         {
             var bitmap = ExtractBitmap(zipArchive, bitmapEntry.Key);
             if (bitmap.HasValue)
             {
                 screenshot.Bitmap = bitmap.Value;
             }
         }
     }
 }