From 5d9bac768af5568c86157aadbf6b35af4ef27f3f Mon Sep 17 00:00:00 2001
From: Niko Ehrenfeuchter <nikolaus.ehrenfeuchter@unibas.ch>
Date: Thu, 1 Feb 2018 13:35:38 +0100
Subject: [PATCH] Show transfer size in human readable units.

Refers to #2
---
 ATxTray/AutoTxTray.cs | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/ATxTray/AutoTxTray.cs b/ATxTray/AutoTxTray.cs
index 256b62c..c07d377 100644
--- a/ATxTray/AutoTxTray.cs
+++ b/ATxTray/AutoTxTray.cs
@@ -4,6 +4,7 @@ using System.Timers;
 using System.Drawing;
 using System.IO;
 using System.Windows.Forms;
+using ATxCommon;
 using ATxCommon.Serializables;
 using Microsoft.WindowsAPICodePack.Dialogs;
 using NLog;
@@ -298,10 +299,12 @@ namespace ATxTray
             _txInProgress = _status.TransferInProgress;
             _txSize = _status.CurrentTransferSize;
             if (_txInProgress) {
-                _miTxProgress.Text = @"Transfer in progress (size: " + _txSize + ")";
+                _miTxProgress.Text = @"Transfer in progress (size: " +
+                    Conv.BytesToString(_txSize) + ")";
                 _miTxProgress.BackColor = Color.LightGreen;
                 _notifyIcon.ShowBalloonTip(500, AppTitle,
-                    "New transfer started (size: " + _txSize + ").", ToolTipIcon.Info);
+                    "New transfer started (size: " +
+                    Conv.BytesToString(_txSize) + ").", ToolTipIcon.Info);
             } else {
                 _miTxProgress.Text = @"No transfer running.";
                 _miTxProgress.ResetBackColor();
-- 
GitLab