314 |
} |
} |
315 |
g_hash_table_insert(Ahash, "iso", &Liso); /* image iso */ |
g_hash_table_insert(Ahash, "iso", &Liso); /* image iso */ |
316 |
if (Lstatus && *Labort==FALSE) { |
if (Lstatus && *Labort==FALSE) { |
317 |
Lextrapara = make_image_getextrapara(Ahash); |
Lextrapara = make_image_getextrapara(Ahash, "data"); |
318 |
g_hash_table_insert(Ahash, "extrapara", &Lextrapara); /* parametres supplementaires */ |
g_hash_table_insert(Ahash, "extrapara", &Lextrapara); /* parametres supplementaires */ |
319 |
Lstatus = make_iso(Ahash, Aerror); |
Lstatus = make_iso(Ahash, Aerror); |
320 |
g_hash_table_remove(Ahash, "extrapara"); |
g_hash_table_remove(Ahash, "extrapara"); |
451 |
return (Tdriveinfo *) g_slist_nth_data(Glistdrives, Lvalue); |
return (Tdriveinfo *) g_slist_nth_data(Glistdrives, Lvalue); |
452 |
} |
} |
453 |
|
|
454 |
|
/* operation gravure dcd de donnee */ |
455 |
|
gboolean burn_dvddata(GHashTable *Ahash, GError **Aerror) |
456 |
|
{ |
457 |
|
gint Ltodo = gtk_spin_button_get_value(GTK_SPIN_BUTTON(g_hash_table_lookup(Ahash, "nbrdvddata"))); |
458 |
|
gboolean Lsimul = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(g_hash_table_lookup(Ahash, "dvddatasimul"))); |
459 |
|
GtkEntry *Lgraveuriso = GTK_ENTRY(g_hash_table_lookup(Ahash, "dstdvddatabtnvalue")); |
460 |
|
GtkWidget *Lgraveur = g_hash_table_lookup(Ahash, "dstdvddatacombo"); |
461 |
|
gint Ldone = 1; |
462 |
|
gchar *Ldst = get_combo_value(Lgraveur); |
463 |
|
gchar *Ltmpdir = NULL; |
464 |
|
gchar *Lextrapara = NULL; |
465 |
|
gchar *Liso = NULL; |
466 |
|
gboolean Loperationstatus = FALSE; |
467 |
|
gboolean Lstatus; |
468 |
|
|
469 |
|
g_hash_table_insert(Ahash, "todo", &Ltodo); /* a faire */ |
470 |
|
g_hash_table_insert(Ahash, "done", &Ldone); /* fais */ |
471 |
|
g_hash_table_insert(Ahash, "operationstatus", &Loperationstatus); /* resultat de l'operation */ |
472 |
|
g_hash_table_insert(Ahash, "gerror", Aerror); /* pointeur retour des erreurs */ |
473 |
|
g_hash_table_insert(Ahash, "tmpdir", &Ltmpdir); /* repertoire temporraire */ |
474 |
|
|
475 |
|
/* on retourne dans ltmp le nom du repertoire temporraire utilise pour |
476 |
|
* l'operation */ |
477 |
|
Lstatus = preparedata(Ahash, Aerror); |
478 |
|
_DEB("ici LDST => %s\n", Ldst); |
479 |
|
|
480 |
|
Lextrapara = make_image_getextrapara(Ahash, "dvddata"); |
481 |
|
g_hash_table_insert(Ahash, "extrapara", &Lextrapara); /* parametres supplementaires */ |
482 |
|
if (strcmp(Ldst, "iso")) { |
483 |
|
Ltodo=Ltodo+(Lsimul ? 2 : 1); /* + 1 pour l'ecriture de l'image iso et 1 pour la simulation */ |
484 |
|
|
485 |
|
Lstatus = burn_dvd(Ahash, Aerror); |
486 |
|
|
487 |
|
} else { |
488 |
|
Liso = _FILENAME(gtk_entry_get_text(Lgraveuriso)); |
489 |
|
Ltodo = 1; |
490 |
|
g_hash_table_insert(Ahash, "iso", &Liso); /* image iso */ |
491 |
|
Lstatus = make_iso(Ahash, Aerror); |
492 |
|
g_hash_table_remove(Ahash, "iso"); |
493 |
|
g_free(Liso); |
494 |
|
} |
495 |
|
g_hash_table_remove(Ahash, "extrapara"); |
496 |
|
g_free(Lextrapara); |
497 |
|
|
498 |
|
deltempdir(Ltmpdir); |
499 |
|
|
500 |
|
g_hash_table_remove(Ahash, "todo"); |
501 |
|
g_hash_table_remove(Ahash, "done"); |
502 |
|
g_hash_table_remove(Ahash, "tmpdir"); g_free(Ltmpdir); |
503 |
|
g_hash_table_remove(Ahash, "operationstatus"); |
504 |
|
g_hash_table_remove(Ahash, "gerror"); |
505 |
|
|
506 |
|
return Lstatus; |
507 |
|
} |
508 |
|
|
509 |
/* |
/* |
510 |
* vim:et:ts=8:sts=2:sw=2 |
* vim:et:ts=8:sts=2:sw=2 |