diff options
Diffstat (limited to 'src/dialogs')
-rw-r--r-- | src/dialogs/add_shellcode.c | 16 | ||||
-rw-r--r-- | src/dialogs/binparts.c | 28 | ||||
-rw-r--r-- | src/dialogs/binparts.h | 2 | ||||
-rw-r--r-- | src/dialogs/export.c | 14 | ||||
-rw-r--r-- | src/dialogs/export.h | 2 | ||||
-rw-r--r-- | src/dialogs/plugins.c | 8 | ||||
-rw-r--r-- | src/dialogs/plugins.h | 2 |
7 files changed, 33 insertions, 39 deletions
diff --git a/src/dialogs/add_shellcode.c b/src/dialogs/add_shellcode.c index 78bfb9d..65e081b 100644 --- a/src/dialogs/add_shellcode.c +++ b/src/dialogs/add_shellcode.c @@ -184,7 +184,7 @@ static void export_assistant_cancel(GtkAssistant *assistant, gpointer data) static void export_assistant_close(GtkAssistant *assistant, GObject *ref) { - GOpenidaBinary *binary; /* Binaire chargé à parcourir */ + GLoadedBinary *binary; /* Binaire chargé à parcourir */ GExeFormat *format; /* Format du binaire */ GRenderingOptions *options; /* Options d'exportation */ GtkToggleButton *checkbutton; /* Coche à retrouver */ @@ -192,9 +192,9 @@ static void export_assistant_close(GtkAssistant *assistant, GObject *ref) GtkEntry *entry; /* Zone de saisie */ const gchar *filename; /* Chemin d'accès du fichier */ - //binary = G_OPENIDA_BINARY(g_object_get_data(ref, "binary")); + //binary = G_LOADED_BINARY(g_object_get_data(ref, "binary")); - format = g_openida_binary_get_format(binary); + format = g_loaded_binary_get_format(binary); options = g_rendering_options_new(format); /* Eléments à afficher */ @@ -285,8 +285,8 @@ static void register_bincode_panel(GtkAssistant *assistant) /* Choix par défaut */ /* - binary = G_OPENIDA_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); - filename = g_openida_binary_get_filename(binary); + binary = G_LOADED_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); + filename = g_loaded_binary_get_filename(binary); gtk_entry_set_text(GTK_ENTRY(entry), filename); gtk_entry_append_text(GTK_ENTRY(entry), ".txt"); @@ -611,7 +611,7 @@ static void register_output_panel(GtkAssistant *assistant) GtkWidget *combobox; /* Sélection du format */ GtkWidget *entry; /* Zone de saisie de texte */ GtkWidget *button; /* Sélection de fichier */ - GOpenidaBinary *binary; /* Binaire chargé à parcourir */ + GLoadedBinary *binary; /* Binaire chargé à parcourir */ const char *filename; /* Chemin d'accès par défaut */ alignment = qck_create_padded_alignment(8, 8, 8, 8); @@ -661,8 +661,8 @@ static void register_output_panel(GtkAssistant *assistant) /* Choix par défaut */ /* - binary = G_OPENIDA_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); - filename = g_openida_binary_get_filename(binary); + binary = G_LOADED_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); + filename = g_loaded_binary_get_filename(binary); gtk_entry_set_text(GTK_ENTRY(entry), filename); gtk_entry_append_text(GTK_ENTRY(entry), ".txt"); diff --git a/src/dialogs/binparts.c b/src/dialogs/binparts.c index 054c7bf..14e1422 100644 --- a/src/dialogs/binparts.c +++ b/src/dialogs/binparts.c @@ -68,7 +68,7 @@ static void save_current_selection(GtkButton *, GObject *); static void close_editor(GtkButton *, GtkWidget *); /* Charge les parties courantes d'un binaire donné. */ -static void load_binary_current_parts(GOpenidaBinary *binary, GObject *ref); +static void load_binary_current_parts(GLoadedBinary *binary, GObject *ref); /* Affiche les parties désassemblées par défaut. */ static void load_default_parts(GObject *); @@ -99,7 +99,7 @@ static void on_part_selection_toggle(GtkCellRendererToggle *, gchar *, GObject * * * ******************************************************************************/ -GtkWidget *create_sections_dialog(GOpenidaBinary *binary, GtkWindow *parent) +GtkWidget *create_sections_dialog(GLoadedBinary *binary, GtkWindow *parent) { GtkWidget *result; /* Fenêtre à renvoyer */ GObject *ref; /* Espace de référencements */ @@ -345,7 +345,7 @@ static void save_current_selection(GtkButton *button, GObject *ref) - GOpenidaBinary *binary; /* Binaire à traiter */ + GLoadedBinary *binary; /* Binaire à traiter */ GExeFormat *format; /* Format associé au binaire */ GArchProcessor *proc; /* Architecture utilisée */ @@ -363,9 +363,9 @@ static void save_current_selection(GtkButton *button, GObject *ref) off_t offset; /* Position dans le binaire */ - binary = G_OPENIDA_BINARY(g_object_get_data(ref, "binary")); + binary = G_LOADED_BINARY(g_object_get_data(ref, "binary")); - format = g_openida_binary_get_format(binary); + format = g_loaded_binary_get_format(binary); proc = get_arch_processor_from_format(format); @@ -402,7 +402,7 @@ static void save_current_selection(GtkButton *button, GObject *ref) } - g_openida_binary_set_parts(binary, BPM_ROUTINES, parts, parts_count); + g_loaded_binary_set_parts(binary, BPM_ROUTINES, parts, parts_count); @@ -451,7 +451,7 @@ static void close_editor(GtkButton *button, GtkWidget *widget) * * ******************************************************************************/ -static void load_binary_current_parts(GOpenidaBinary *binary, GObject *ref) +static void load_binary_current_parts(GLoadedBinary *binary, GObject *ref) { GtkTreeModel *store; /* Modèle de représentation */ GBinPart ***list; /* Tableau de parties choisies */ @@ -472,7 +472,7 @@ static void load_binary_current_parts(GOpenidaBinary *binary, GObject *ref) store = GTK_TREE_MODEL(g_object_get_data(ref, "store")); - list = g_openida_binary_get_parts(binary, &model, &count); + list = g_loaded_binary_get_parts(binary, &model, &count); for (i = 0; i < (BPM_COUNT - 1 /* TODO*/); i++) { @@ -535,7 +535,7 @@ static void load_binary_current_parts(GOpenidaBinary *binary, GObject *ref) static void load_default_parts(GObject *ref) { - GOpenidaBinary *binary; /* Binaire à traiter */ + GLoadedBinary *binary; /* Binaire à traiter */ GtkTreeStore *store; /* Modèle de gestion */ GExeFormat *format; /* Format associé au binaire */ GArchProcessor *proc; /* Architecture utilisée */ @@ -550,10 +550,10 @@ static void load_default_parts(GObject *ref) char end[VMPA_MAX_SIZE]; /* Version humainement lisible */ GtkTreeIter iter; /* Point d'insertion */ - binary = G_OPENIDA_BINARY(g_object_get_data(ref, "binary")); + binary = G_LOADED_BINARY(g_object_get_data(ref, "binary")); store = GTK_TREE_STORE(g_object_get_data(ref, "store")); - format = g_openida_binary_get_format(binary); + format = g_loaded_binary_get_format(binary); proc = get_arch_processor_from_format(format); parts = g_exe_format_get_parts(format, &parts_count); @@ -609,7 +609,7 @@ static void load_default_parts(GObject *ref) static void load_routines_parts(GObject *ref) { - GOpenidaBinary *binary; /* Binaire à traiter */ + GLoadedBinary *binary; /* Binaire à traiter */ GtkTreeStore *store; /* Modèle de gestion */ GExeFormat *format; /* Format associé au binaire */ GArchProcessor *proc; /* Architecture utilisée */ @@ -623,10 +623,10 @@ static void load_routines_parts(GObject *ref) char end[VMPA_MAX_SIZE]; /* Version humainement lisible */ GtkTreeIter iter; /* Point d'insertion */ - binary = G_OPENIDA_BINARY(g_object_get_data(ref, "binary")); + binary = G_LOADED_BINARY(g_object_get_data(ref, "binary")); store = GTK_TREE_STORE(g_object_get_data(ref, "store")); - format = g_openida_binary_get_format(binary); + format = g_loaded_binary_get_format(binary); proc = get_arch_processor_from_format(format); routines = g_binary_format_get_routines(G_BIN_FORMAT(format), &routines_count); diff --git a/src/dialogs/binparts.h b/src/dialogs/binparts.h index 0880f85..e21d990 100644 --- a/src/dialogs/binparts.h +++ b/src/dialogs/binparts.h @@ -33,7 +33,7 @@ /* Construit la fenêtre de sélection des sections. */ -GtkWidget *create_sections_dialog(GOpenidaBinary *, GtkWindow *); +GtkWidget *create_sections_dialog(GLoadedBinary *, GtkWindow *); diff --git a/src/dialogs/export.c b/src/dialogs/export.c index e514511..317ada4 100644 --- a/src/dialogs/export.c +++ b/src/dialogs/export.c @@ -103,7 +103,7 @@ static void register_content_panel(GtkAssistant *); * * ******************************************************************************/ -void run_export_assistant(GOpenidaBinary *binary, GtkWindow *parent) +void run_export_assistant(GLoadedBinary *binary, GtkWindow *parent) { GtkWidget *assistant; /* Fenêtre à afficher */ GObject *ref; /* Espace de référencement */ @@ -170,7 +170,7 @@ static void export_assistant_close(GtkAssistant *assistant, GObject *ref) int fd; /* Descripteur de la sortie */ struct _export_data *export; /* Informations à faire suivre */ GtkToggleButton *checkbutton; /* Coche à retrouver */ - GOpenidaBinary *binary; /* Binaire chargé à parcourir */ + GLoadedBinary *binary; /* Binaire chargé à parcourir */ GCodeBuffer *buffer; /* Tampon de code à traiter */ /* Fichier de sortie */ @@ -206,9 +206,9 @@ static void export_assistant_close(GtkAssistant *assistant, GObject *ref) /* Programmation de la tâche */ - binary = G_OPENIDA_BINARY(g_object_get_data(ref, "binary")); + binary = G_LOADED_BINARY(g_object_get_data(ref, "binary")); - buffer = g_openida_binary_get_disassembled_buffer(binary); + buffer = g_loaded_binary_get_disassembled_buffer(binary); g_buffer_code_scan(buffer, 0, VMPA_MAX, _("Exporting binary lines..."), (process_line_fc)export_buffer_line, export); @@ -277,7 +277,7 @@ static void register_output_panel(GtkAssistant *assistant) GtkWidget *combobox; /* Sélection du format */ GtkWidget *entry; /* Zone de saisie de texte */ GtkWidget *button; /* Sélection de fichier */ - GOpenidaBinary *binary; /* Binaire chargé à parcourir */ + GLoadedBinary *binary; /* Binaire chargé à parcourir */ const char *filename; /* Chemin d'accès par défaut */ alignment = qck_create_padded_alignment(8, 8, 8, 8); @@ -327,8 +327,8 @@ static void register_output_panel(GtkAssistant *assistant) /* Choix par défaut */ - binary = G_OPENIDA_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); - filename = g_openida_binary_get_filename(binary); + binary = G_LOADED_BINARY(g_object_get_data(G_OBJECT(assistant), "binary")); + filename = g_loaded_binary_get_filename(binary, true); gtk_entry_set_text(GTK_ENTRY(entry), filename); gtk_editable_insert_text(GTK_EDITABLE(entry), ".txt", -1, (gint []) { strlen(filename) }); diff --git a/src/dialogs/export.h b/src/dialogs/export.h index c14d05d..3274b12 100644 --- a/src/dialogs/export.h +++ b/src/dialogs/export.h @@ -30,7 +30,7 @@ /* Crée et affiche un assistant d'aide à l'exportation. */ -void run_export_assistant(GOpenidaBinary *, GtkWindow *); +void run_export_assistant(GLoadedBinary *, GtkWindow *); diff --git a/src/dialogs/plugins.c b/src/dialogs/plugins.c index b5e045b..e74296e 100644 --- a/src/dialogs/plugins.c +++ b/src/dialogs/plugins.c @@ -47,7 +47,7 @@ * * ******************************************************************************/ -GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *parent) +GtkWidget *create_plugins_selection_dialog(GLoadedBinary *binary, GtkWindow *parent) { GtkWidget *result; /* Fenêtre à renvoyer */ GObject *ref; /* Espace de référencements */ @@ -146,7 +146,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button7 = gtk_button_new(); gtk_widget_show(button7); gtk_container_add(GTK_CONTAINER(vbuttonbox1), button7); - GTK_WIDGET_SET_FLAGS(button7, GTK_CAN_DEFAULT); image3 = gtk_image_new_from_stock("gtk-add", GTK_ICON_SIZE_BUTTON); gtk_widget_show(image3); @@ -155,7 +154,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button8 = gtk_button_new(); gtk_widget_show(button8); gtk_container_add(GTK_CONTAINER(vbuttonbox1), button8); - GTK_WIDGET_SET_FLAGS(button8, GTK_CAN_DEFAULT); image4 = gtk_image_new_from_stock("gtk-remove", GTK_ICON_SIZE_BUTTON); gtk_widget_show(image4); @@ -174,7 +172,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button9 = gtk_button_new(); gtk_widget_show(button9); gtk_container_add(GTK_CONTAINER(vbuttonbox2), button9); - GTK_WIDGET_SET_FLAGS(button9, GTK_CAN_DEFAULT); image5 = gtk_image_new_from_stock("gtk-go-up", GTK_ICON_SIZE_BUTTON); gtk_widget_show(image5); @@ -183,7 +180,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button10 = gtk_button_new(); gtk_widget_show(button10); gtk_container_add(GTK_CONTAINER(vbuttonbox2), button10); - GTK_WIDGET_SET_FLAGS(button10, GTK_CAN_DEFAULT); image6 = gtk_image_new_from_stock("gtk-go-down", GTK_ICON_SIZE_BUTTON); gtk_widget_show(image6); @@ -276,7 +272,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button1 = gtk_button_new(); gtk_widget_show(button1); gtk_container_add(GTK_CONTAINER(hbuttonbox1), button1); - GTK_WIDGET_SET_FLAGS(button1, GTK_CAN_DEFAULT); alignment1 = gtk_alignment_new(0.5, 0.5, 0, 0); gtk_widget_show(alignment1); @@ -297,7 +292,6 @@ GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *binary, GtkWindow *pa button2 = gtk_button_new(); gtk_widget_show(button2); gtk_container_add(GTK_CONTAINER(hbuttonbox1), button2); - GTK_WIDGET_SET_FLAGS(button2, GTK_CAN_DEFAULT); alignment2 = gtk_alignment_new(0.5, 0.5, 0, 0); gtk_widget_show(alignment2); diff --git a/src/dialogs/plugins.h b/src/dialogs/plugins.h index f0ea164..32901fb 100644 --- a/src/dialogs/plugins.h +++ b/src/dialogs/plugins.h @@ -33,7 +33,7 @@ /* Construit la fenêtre de sélection des sections. */ -GtkWidget *create_plugins_selection_dialog(GOpenidaBinary *, GtkWindow *); +GtkWidget *create_plugins_selection_dialog(GLoadedBinary *, GtkWindow *); |