class Infobar::Timer

def add(time, count)

def add(time, count)
  case @n
  when 0
    @n += 1
  when 1
    @n -= 1
    duration = time - @time_last
    self << (duration / @count_last)
    self << (duration / count.to_f)
  else
    duration = time - @time_last
    self << (duration / count.to_f)
  end
  @time_last, @count_last = time, count
  self
end