This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ProgressBar : IDisposable, IProgress<double> | |
{ | |
private const int blockCount = 10; | |
private readonly TimeSpan animationInterval = TimeSpan.FromSeconds(1.0 / 8); | |
private const string animation = @"|/-\"; | |
private readonly Timer timer; | |
private double currentProgress = 0; | |
private string currentText = string.Empty; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.Generic; | |
using System.Globalization; | |
namespace HumanReadable | |
{ | |
public class HumanReadableBytes | |
{ | |
private readonly Dictionary<Base, Unit[]> _baseUnits = new Dictionary<Base, Unit[]>(); | |
public int DecimalPoints = 2; | |
public int DecimalsAfterPower = 2; |
OlderNewer