Skip to content

Stopping

Jeff Felchner edited this page Jul 13, 2016 · 3 revisions

The bar can be stopped in four ways:

  • #finish: Will stop the bar by completing it immediately. The current position will be advanced to the total.
  • #stop: Will stop the bar by immediately cancelling it. The current position will remain where it is.
  • #pause: Will stop the bar like #stop but will allow it to be restarted from where it previously left off by calling #resume. Note: Elapsed Time and Estimated Time will stop being affected while the bar is paused.
  • #reset: Will stop the bar by resetting all information. The current position of the bar will be reset to where it began when it was created. (eg if you passed :starting_at => 5 when you created the bar, it would reset to 5 and not 0)

Animated:

Starting and Stopping the Bar Animation