- bool inform_of_finish = false;
- string const st = (*i)->status ();
-
- if (!(*i)->finished ()) {
- float const p = (*i)->overall_progress ();
- if (p >= 0) {
-// r[_columns.text] = st;
- _job_records[*i].gauge->SetValue (p * 100);
- } else {
-// r[_columns.text] = "Running";
- _job_records[*i].gauge->Pulse ();
- }
- }
-
- /* Hack to work around our lack of cross-thread
- signalling; we tell the job to emit_finished()
- from here (the GUI thread).
- */
-
- if ((*i)->finished_ok ()) {
- if (!_job_records[*i].informed_of_finish) {
- _job_records[*i].gauge->SetValue (100);
-// r[_columns.text] = st;
- inform_of_finish = true;
- }
- } else if ((*i)->finished_in_error ()) {
- if (!_job_records[*i].informed_of_finish) {
- _job_records[*i].gauge->SetValue (100);
-// r[_columns.text] = st;
- inform_of_finish = true;
- }
- }
+void
+JobManagerView::replace ()
+{
+ /* Make a new version of _job_records which reflects the order in JobManager's job list */
+
+ list<shared_ptr<JobView> > new_job_records;