Skip to content
Snippets Groups Projects
Commit 5d9bac76 authored by Niko Ehrenfeuchter's avatar Niko Ehrenfeuchter :keyboard:
Browse files

Show transfer size in human readable units.

Refers to #2
parent 596e8c3d
No related branches found
No related tags found
No related merge requests found
...@@ -4,6 +4,7 @@ using System.Timers; ...@@ -4,6 +4,7 @@ using System.Timers;
using System.Drawing; using System.Drawing;
using System.IO; using System.IO;
using System.Windows.Forms; using System.Windows.Forms;
using ATxCommon;
using ATxCommon.Serializables; using ATxCommon.Serializables;
using Microsoft.WindowsAPICodePack.Dialogs; using Microsoft.WindowsAPICodePack.Dialogs;
using NLog; using NLog;
...@@ -298,10 +299,12 @@ namespace ATxTray ...@@ -298,10 +299,12 @@ namespace ATxTray
_txInProgress = _status.TransferInProgress; _txInProgress = _status.TransferInProgress;
_txSize = _status.CurrentTransferSize; _txSize = _status.CurrentTransferSize;
if (_txInProgress) { if (_txInProgress) {
_miTxProgress.Text = @"Transfer in progress (size: " + _txSize + ")"; _miTxProgress.Text = @"Transfer in progress (size: " +
Conv.BytesToString(_txSize) + ")";
_miTxProgress.BackColor = Color.LightGreen; _miTxProgress.BackColor = Color.LightGreen;
_notifyIcon.ShowBalloonTip(500, AppTitle, _notifyIcon.ShowBalloonTip(500, AppTitle,
"New transfer started (size: " + _txSize + ").", ToolTipIcon.Info); "New transfer started (size: " +
Conv.BytesToString(_txSize) + ").", ToolTipIcon.Info);
} else { } else {
_miTxProgress.Text = @"No transfer running."; _miTxProgress.Text = @"No transfer running.";
_miTxProgress.ResetBackColor(); _miTxProgress.ResetBackColor();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment