diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/analysis/db/items/comment.c | 2 | ||||
-rw-r--r-- | src/arch/instruction.c | 2 | ||||
-rw-r--r-- | src/format/symbol.c | 2 | ||||
-rw-r--r-- | src/glibext/gbinarycursor.c | 25 | ||||
-rw-r--r-- | src/glibext/gbinarycursor.h | 5 | ||||
-rw-r--r-- | src/glibext/gbinportion.c | 2 | ||||
-rw-r--r-- | src/glibext/generators/hex.c | 2 | ||||
-rw-r--r-- | src/glibext/generators/prologue.c | 2 | ||||
-rw-r--r-- | src/glibext/generators/rborder.c | 2 | ||||
-rw-r--r-- | src/gtkext/gtkgraphdisplay.c | 2 | ||||
-rw-r--r-- | src/gui/dialogs/export_graph.c | 2 | ||||
-rw-r--r-- | src/gui/editem-int.h | 2 | ||||
-rw-r--r-- | src/gui/menus/edition.c | 8 |
13 files changed, 43 insertions, 15 deletions
diff --git a/src/analysis/db/items/comment.c b/src/analysis/db/items/comment.c index 47ab5b3..1c1025e 100644 --- a/src/analysis/db/items/comment.c +++ b/src/analysis/db/items/comment.c @@ -1389,7 +1389,7 @@ static int g_db_comment_contains_cursor(const GDbComment *comment, size_t index, assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); result = cmp_vmpa(&addr, &comment->addr); diff --git a/src/arch/instruction.c b/src/arch/instruction.c index 5880c34..f571330 100644 --- a/src/arch/instruction.c +++ b/src/arch/instruction.c @@ -1771,7 +1771,7 @@ static int g_arch_instruction_contains_cursor(const GArchInstruction *instr, siz assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); result = cmp_mrange_with_vmpa(&instr->range, &addr); diff --git a/src/format/symbol.c b/src/format/symbol.c index 149dd2a..f16e0a9 100644 --- a/src/format/symbol.c +++ b/src/format/symbol.c @@ -552,7 +552,7 @@ static int g_binary_symbol_contains_cursor(const GBinSymbol *symbol, size_t inde assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); /** * En tant que générateur, le symbole ne couvre qu'une ou plusieurs lignes diff --git a/src/glibext/gbinarycursor.c b/src/glibext/gbinarycursor.c index 86f931f..5d4c0f8 100644 --- a/src/glibext/gbinarycursor.c +++ b/src/glibext/gbinarycursor.c @@ -416,6 +416,29 @@ void g_binary_cursor_set_raw(GBinaryCursor *cursor, bool raw) /****************************************************************************** * * +* Paramètres : cursor = suivi de positions à consulter. * +* * +* Description : Indique la représentation de l'emplacement. * +* * +* Retour : true so la représentation de l'emplacement est brute. * +* * +* Remarques : - * +* * +******************************************************************************/ + +bool g_binary_cursor_is_raw(const GBinaryCursor *cursor) +{ + bool result; /* Statut à retourner */ + + result = cursor->raw; + + return result; + +} + + +/****************************************************************************** +* * * Paramètres : cursor = suivi de positions à mettre à jour. * * addr = emplacement dans le binaire visé. * * * @@ -447,7 +470,7 @@ void g_binary_cursor_update(GBinaryCursor *cursor, const vmpa2t *addr) * * ******************************************************************************/ -void g_binary_cursor_get_info(const GBinaryCursor *cursor, vmpa2t *addr) +void g_binary_cursor_retrieve(const GBinaryCursor *cursor, vmpa2t *addr) { copy_vmpa(addr, &cursor->addr); diff --git a/src/glibext/gbinarycursor.h b/src/glibext/gbinarycursor.h index defcb56..082d80f 100644 --- a/src/glibext/gbinarycursor.h +++ b/src/glibext/gbinarycursor.h @@ -57,6 +57,9 @@ GType g_binary_cursor_get_type(void); /* Crée un nouveau suivi de positions dans un panneau. */ GLineCursor *g_binary_cursor_new(void); +/* Indique la représentation de l'emplacement. */ +bool g_binary_cursor_is_raw(const GBinaryCursor *); + /* Précise la représentation de l'emplacement. */ void g_binary_cursor_set_raw(GBinaryCursor *, bool); @@ -64,7 +67,7 @@ void g_binary_cursor_set_raw(GBinaryCursor *, bool); void g_binary_cursor_update(GBinaryCursor *, const vmpa2t *); /* Transmet la position de suivi dans un panneau de chargement. */ -void g_binary_cursor_get_info(const GBinaryCursor *, vmpa2t *); +void g_binary_cursor_retrieve(const GBinaryCursor *, vmpa2t *); diff --git a/src/glibext/gbinportion.c b/src/glibext/gbinportion.c index 0074713..f7b3832 100644 --- a/src/glibext/gbinportion.c +++ b/src/glibext/gbinportion.c @@ -1071,7 +1071,7 @@ static int g_binary_portion_contains_cursor(const GBinPortion *portion, size_t i assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); result = cmp_vmpa(&addr, get_mrange_addr(&portion->range)); diff --git a/src/glibext/generators/hex.c b/src/glibext/generators/hex.c index 48fc5b3..6a0287d 100644 --- a/src/glibext/generators/hex.c +++ b/src/glibext/generators/hex.c @@ -386,7 +386,7 @@ static int g_hex_generator_contains_cursor(const GHexGenerator *generator, size_ assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); init_vmpa(&pos, generator->bytes_per_line * index, VMPA_NO_VIRTUAL); diff --git a/src/glibext/generators/prologue.c b/src/glibext/generators/prologue.c index 63d326b..133220d 100644 --- a/src/glibext/generators/prologue.c +++ b/src/glibext/generators/prologue.c @@ -328,7 +328,7 @@ static int g_intro_generator_contains_cursor(const GIntroGenerator *generator, s assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); result = cmp_vmpa(&addr, &generator->addr); diff --git a/src/glibext/generators/rborder.c b/src/glibext/generators/rborder.c index 640fa2d..7d90f79 100644 --- a/src/glibext/generators/rborder.c +++ b/src/glibext/generators/rborder.c @@ -305,7 +305,7 @@ static int g_border_generator_contains_cursor(const GBorderGenerator *generator, assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); result = cmp_vmpa(&addr, &generator->addr); diff --git a/src/gtkext/gtkgraphdisplay.c b/src/gtkext/gtkgraphdisplay.c index ed3c923..95a9d01 100644 --- a/src/gtkext/gtkgraphdisplay.c +++ b/src/gtkext/gtkgraphdisplay.c @@ -917,7 +917,7 @@ static void gtk_graph_display_prepare_for_cursor(GtkGraphDisplay *display, const assert(G_IS_BINARY_CURSOR(cursor)); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); if (display->routine == NULL) need_update = true; diff --git a/src/gui/dialogs/export_graph.c b/src/gui/dialogs/export_graph.c index 55556b6..0af0203 100644 --- a/src/gui/dialogs/export_graph.c +++ b/src/gui/dialogs/export_graph.c @@ -117,7 +117,7 @@ void run_graph_export_assistant(GLoadedBinary *binary, GtkGraphDisplay *display, if (cursor != NULL) { - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &target); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &target); g_object_unref(G_OBJECT(cursor)); diff --git a/src/gui/editem-int.h b/src/gui/editem-int.h index 744a55f..cf2d813 100644 --- a/src/gui/editem-int.h +++ b/src/gui/editem-int.h @@ -79,8 +79,10 @@ struct _GEditorItemClass change_item_content_fc change_content; /* Changement de contenu */ change_item_view_fc change_view; /* Rechargement dû à une vue */ update_item_view_fc update_view; /* Rechargement dû à évolutions*/ + track_cursor_in_view_fc track_cursor; /* Suivi des positions */ focus_cursor_fc focus_cursor; /* Prête attention à une addr. */ + update_project_fc update_project; /* Actualisation des binaires */ }; diff --git a/src/gui/menus/edition.c b/src/gui/menus/edition.c index 2cfcf85..cdf8aa3 100644 --- a/src/gui/menus/edition.c +++ b/src/gui/menus/edition.c @@ -487,7 +487,7 @@ static void mcb_edition_switch_numeric_operand(GtkMenuItem *menuitem, gpointer u assert(G_IS_IMM_OPERAND(creator)); cursor = g_loaded_panel_get_cursor(panel); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); g_object_unref(G_OBJECT(cursor)); binary = G_LOADED_BINARY(get_current_content()); @@ -570,7 +570,7 @@ static void mcb_edition_follow_ref(GtkMenuItem *menuitem, gpointer unused) proc = g_loaded_binary_get_processor(binary); cursor = g_loaded_panel_get_cursor(panel); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &iaddr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &iaddr); g_object_unref(G_OBJECT(cursor)); defined = g_targetable_operand_get_addr(G_TARGETABLE_OPERAND(creator), &iaddr, format, proc, &addr); @@ -624,7 +624,7 @@ static void mcb_edition_list_xrefs(GtkMenuItem *menuitem, GMenuBar *bar) assert(GTK_IS_BLOCK_DISPLAY(panel) || GTK_IS_GRAPH_DISPLAY(panel)); cursor = g_loaded_panel_get_cursor(panel); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); g_object_unref(G_OBJECT(cursor)); binary = G_LOADED_BINARY(get_current_content()); @@ -703,7 +703,7 @@ static void mcb_edition_bookmarks_toggle(GtkMenuItem *menuitem, GMenuBar *bar) assert(GTK_IS_BLOCK_DISPLAY(panel) || GTK_IS_GRAPH_DISPLAY(panel)); cursor = g_loaded_panel_get_cursor(panel); - g_binary_cursor_get_info(G_BINARY_CURSOR(cursor), &addr); + g_binary_cursor_retrieve(G_BINARY_CURSOR(cursor), &addr); g_object_unref(G_OBJECT(cursor)); /* Accès à la collection */ |