mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
(tasks) Show finished tasks progress too
This commit is contained in:
parent
c03e1547b1
commit
916444f977
@ -54,24 +54,6 @@ static rarch_task_t *task_queue_get(task_queue_t *queue)
|
||||
return task;
|
||||
}
|
||||
|
||||
static void rarch_task_internal_gather(void)
|
||||
{
|
||||
rarch_task_t *task;
|
||||
while ((task = task_queue_get(&tasks_finished)) != NULL)
|
||||
{
|
||||
if (task->callback)
|
||||
task->callback(task->task_data, task->user_data, task->error);
|
||||
|
||||
if (task->error)
|
||||
free(task->error);
|
||||
|
||||
if (task->title)
|
||||
free(task->title);
|
||||
|
||||
free(task);
|
||||
}
|
||||
}
|
||||
|
||||
static void push_task_progress(rarch_task_t *task)
|
||||
{
|
||||
if (task->title)
|
||||
@ -94,6 +76,26 @@ static void push_task_progress(rarch_task_t *task)
|
||||
}
|
||||
}
|
||||
|
||||
static void rarch_task_internal_gather(void)
|
||||
{
|
||||
rarch_task_t *task;
|
||||
while ((task = task_queue_get(&tasks_finished)) != NULL)
|
||||
{
|
||||
push_task_progress(task);
|
||||
|
||||
if (task->callback)
|
||||
task->callback(task->task_data, task->user_data, task->error);
|
||||
|
||||
if (task->error)
|
||||
free(task->error);
|
||||
|
||||
if (task->title)
|
||||
free(task->title);
|
||||
|
||||
free(task);
|
||||
}
|
||||
}
|
||||
|
||||
static void regular_push_running(rarch_task_t *task)
|
||||
{
|
||||
task_queue_put(&tasks_running, task);
|
||||
|
Loading…
x
Reference in New Issue
Block a user