Ignore:
Timestamp:
Jun 28, 2010, 9:44:19 AM (11 years ago)
Author:
Paul Lelgemann
Message:

o KeySearcher: small visualization fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/KeySearcher/P2P/Presentation/StatisticsGenerator.cs

    r1708 r1709  
    7070        void ElapsedTimeTimerTick(object sender, EventArgs e)
    7171        {
    72             status.ElapsedTime = DateTime.Now.Subtract(status.StartDate);
     72            if (status.StartDate != DateTime.MinValue)
     73                status.ElapsedTime = DateTime.Now.Subtract(status.StartDate);
    7374
    7475            if (status.RemainingTimeTotal > new TimeSpan(0))
     
    160161            catch (ArgumentOutOfRangeException)
    161162            {
    162                 status.EstimatedFinishDate = "~";
    163                 status.RemainingTimeTotal = new TimeSpan(-1);
     163                status.RemainingTimeTotal = TimeSpan.MaxValue;
     164                var yearsRemaining = secondsRemaining/60/60/24/365;
     165                status.EstimatedFinishDate = string.Format("{0:0.00e+0} years", yearsRemaining);
    164166            }
    165167
Note: See TracChangeset for help on using the changeset viewer.