feature: now image file previewer shows the image size and file size

This commit is contained in:
leo 2024-09-14 16:13:40 +08:00
parent 7f87ce3431
commit d6b21bad17
No known key found for this signature in database
7 changed files with 388 additions and 331 deletions

View file

@ -10,6 +10,9 @@ namespace SourceGit.Models
public class RevisionImageFile
{
public Bitmap Image { get; set; } = null;
public long FileSize { get; set; } = 0;
public string ImageType { get; set; } = string.Empty;
public string ImageSize => Image != null ? $"{Image.PixelSize.Width} x {Image.PixelSize.Height}" : "0 x 0";
}
public class RevisionTextFile