MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / ghb_queue_update_status

Function ghb_queue_update_status

gtk/src/queuehandler.c:1306–1334  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1304}
1305
1306void ghb_queue_update_status (signal_user_data_t *ud, int index, int status)
1307{
1308 int count = ghb_array_len(ud->queue);
1309 if (index < 0 || index >= count)
1310 {
1311 // invalid index
1312 return;
1313 }
1314
1315 GhbValue * queueDict, * uiDict;
1316 queueDict = ghb_array_get(ud->queue, index);
1317 if (queueDict == NULL) // should never happen
1318 {
1319 return;
1320 }
1321 uiDict = ghb_dict_get(queueDict, "uiSettings");
1322 if (uiDict == NULL) // should never happen
1323 {
1324 return;
1325 }
1326
1327 if (ghb_dict_get_int(uiDict, "job_status") == GHB_QUEUE_RUNNING)
1328 {
1329 return; // Never change the status of currently running jobs
1330 }
1331
1332 ghb_dict_set_int(uiDict, "job_status", status);
1333 ghb_queue_item_set_status(ud, index, status);
1334}
1335
1336static void
1337queue_update_all_status (signal_user_data_t *ud, int status)

Callers 3

queue_update_all_statusFunction · 0.85
queue_reset_action_cbFunction · 0.85

Calls 3

ghb_dict_get_intFunction · 0.85
ghb_dict_set_intFunction · 0.85

Tested by

no test coverage detected