Beispiel #1
0
    def _recompute_async(self):
        self._update(status=BAONStatus.IN_PROGRESS, data=ProgressInfo.make_indeterminate())

        self.parent()._start_worker(
            work=lambda check_abort: self._recompute_async_impl(check_abort, *self._input_values()),
            on_finished=self.set_data,
        )
Beispiel #2
0
    def _recompute_async_impl(self, check_abort, renamed_files, start_planning):
        self._on_async_progress(ProgressInfo.make_indeterminate())

        rename_plan = make_rename_plan(renamed_files)

        save_rename_plan_backup(rename_plan)

        try:
            rename_plan.execute(self._on_async_progress)
        finally:
            delete_rename_plan_backup()

        return True
Beispiel #3
0
 def report_indeterminate_progress(self):
     if self._on_progress is not None:
         self._on_progress(ProgressInfo.make_indeterminate())