Pulse the progress bar 'automatically' if we haven't had a progress update for a...
[dcpomatic.git] / src / wx / job_view.cc
index 231176e4fd96c773d1f96a779de648647f0ddf3a..77620142473af4a6d0823da4c283d2ffefbad0d9 100644 (file)
@@ -103,8 +103,11 @@ JobView::setup ()
 void
 JobView::maybe_pulse ()
 {
-       if (_gauge && _job->running() && !_job->progress()) {
-               _gauge->Pulse ();
+       if (_gauge && _job->running()) {
+               auto elapsed = _job->seconds_since_last_progress_update();
+               if (!_job->progress() || !elapsed || *elapsed > 2) {
+                       _gauge->Pulse ();
+               }
        }
 }