Improve comvert to mp3 task

- Improve progress reporting and cancellation performance
- Clear current book from queue before queueing single convert to mp3 task
This commit is contained in:
MBucari
2025-07-25 15:35:03 -06:00
parent accedeb1b1
commit b27325cdcb
2 changed files with 72 additions and 40 deletions

View File

@@ -111,6 +111,8 @@ public class ProcessQueueViewModel : ReactiveObject
var preLiberated = libraryBooks.Where(lb => !lb.AbsentFromLastScan && lb.Book.UserDefinedItem.BookStatus is LiberatedStatus.Liberated && lb.Book.ContentType is DataLayer.ContentType.Product).ToArray();
if (preLiberated.Length > 0)
{
if (preLiberated.Length == 1)
RemoveCompleted(preLiberated[0]);
Serilog.Log.Logger.Information("Begin convert {count} books to mp3", preLiberated.Length);
AddConvertMp3(preLiberated);
return true;