summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/pychrysalide/glibext/bufferline.c36
-rw-r--r--plugins/ropgadgets/select.c2
-rw-r--r--src/glibext/buffercache.c2
-rw-r--r--src/glibext/bufferline.c25
-rw-r--r--src/glibext/bufferline.h16
5 files changed, 5 insertions, 76 deletions
diff --git a/plugins/pychrysalide/glibext/bufferline.c b/plugins/pychrysalide/glibext/bufferline.c
index dc59b85..274300a 100644
--- a/plugins/pychrysalide/glibext/bufferline.c
+++ b/plugins/pychrysalide/glibext/bufferline.c
@@ -57,9 +57,6 @@ static PyObject *py_buffer_line_add_flag(PyObject *, PyObject *);
/* Retire une propriété particulière à une ligne donnée. */
static PyObject *py_buffer_line_remove_flag(PyObject *, PyObject *);
-/* Fournit l'emplacement où se situe un symbole. */
-static PyObject *py_buffer_line_get_range(PyObject *, void *);
-
/* Renseigne sur les propriétés particulières liées à une ligne. */
static PyObject *py_buffer_line_get_flags(PyObject *, void *);
@@ -322,35 +319,6 @@ static PyObject *py_buffer_line_remove_flag(PyObject *self, PyObject *args)
* Paramètres : self = objet Python concerné par l'appel. *
* closure = non utilisé ici. *
* *
-* Description : Indique la zone mémoire où se situe la ligne. *
-* *
-* Retour : Emplacement mémoire virtuel ou physique. *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-static PyObject *py_buffer_line_get_range(PyObject *self, void *closure)
-{
- PyObject *result; /* Valeur à retourner */
- GBufferLine *line; /* Elément à consulter */
- const mrange_t *range; /* Couverture courante */
-
- line = G_BUFFER_LINE(pygobject_get(self));
- range = g_buffer_line_get_range(line);
-
- result = build_from_internal_mrange(range);
-
- return result;
-
-}
-
-
-/******************************************************************************
-* *
-* Paramètres : self = objet Python concerné par l'appel. *
-* closure = non utilisé ici. *
-* *
* Description : Renseigne sur les propriétés particulières liées à une ligne.*
* *
* Retour : Propriétés intégrées. *
@@ -447,10 +415,6 @@ PyTypeObject *get_python_buffer_line_type(void)
static PyGetSetDef py_buffer_line_getseters[] = {
{
- "range", py_buffer_line_get_range, NULL,
- "Range covered by the line.", NULL
- },
- {
"flags", py_buffer_line_get_flags, NULL,
"Current flags of the buffer line.", NULL
},
diff --git a/plugins/ropgadgets/select.c b/plugins/ropgadgets/select.c
index 9df71bb..099560a 100644
--- a/plugins/ropgadgets/select.c
+++ b/plugins/ropgadgets/select.c
@@ -1533,7 +1533,7 @@ static void add_new_gadgets_for_category(GExeFormat *format, GtkComboBoxText *co
{
instr = chain->instrs[j];
- line = g_buffer_line_new(UNUSED_MRANGE_PTR, BLC_ASSEMBLY);
+ line = g_buffer_line_new(BLC_ASSEMBLY);
g_line_generator_print(G_LINE_GENERATOR(instr), line, -1, 0, content);
if (j == 0)
diff --git a/src/glibext/buffercache.c b/src/glibext/buffercache.c
index bfc2360..04d6dba 100644
--- a/src/glibext/buffercache.c
+++ b/src/glibext/buffercache.c
@@ -394,7 +394,7 @@ static GBufferLine *get_cache_info_line(cache_info *info, size_t index, const GB
if (result == NULL)
{
- result = g_buffer_line_new(UNUSED_MRANGE_PTR, 0/* !! */);
+ result = g_buffer_line_new(0/* !! */);
g_object_add_toggle_ref(G_OBJECT(result), (GToggleNotify)on_line_ref_toggle, info);
diff --git a/src/glibext/bufferline.c b/src/glibext/bufferline.c
index ba25b8f..3e93c9c 100644
--- a/src/glibext/bufferline.c
+++ b/src/glibext/bufferline.c
@@ -241,8 +241,7 @@ static void g_buffer_line_finalize(GBufferLine *line)
/******************************************************************************
* *
-* Paramètres : range = emplacement où va se situer la ligne. *
-* main = colonne à référencer comme étant la principale. *
+* Paramètres : main = colonne à référencer comme étant la principale. *
* *
* Description : Crée une nouvelle représentation de fragments de texte. *
* *
@@ -252,13 +251,12 @@ static void g_buffer_line_finalize(GBufferLine *line)
* *
******************************************************************************/
-GBufferLine *g_buffer_line_new(const mrange_t *range, BufferLineColumn main)
+GBufferLine *g_buffer_line_new(BufferLineColumn main)
{
GBufferLine *result; /* Composant à retourner */
result = g_object_new(G_TYPE_BUFFER_LINE, NULL);
- copy_mrange(&result->range, range);
result->main_column = main;
return result;
@@ -268,25 +266,6 @@ GBufferLine *g_buffer_line_new(const mrange_t *range, BufferLineColumn main)
/******************************************************************************
* *
-* Paramètres : line = ligne à venir consulter. *
-* *
-* Description : Indique la zone mémoire où se situe la ligne. *
-* *
-* Retour : Emplacement mémoire virtuel ou physique. *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-const mrange_t *g_buffer_line_get_range(const GBufferLine *line)
-{
- return &line->range;
-
-}
-
-
-/******************************************************************************
-* *
* Paramètres : line = ligne à venir compléter. *
* col = indice de la colonne à constituer. *
* size = taille souhaitée de l'impression des positions. *
diff --git a/src/glibext/bufferline.h b/src/glibext/bufferline.h
index cfb4432..b911c21 100644
--- a/src/glibext/bufferline.h
+++ b/src/glibext/bufferline.h
@@ -104,10 +104,7 @@ typedef enum _BufferLineFlags
GType g_buffer_line_get_type(void);
/* Crée une nouvelle représentation de fragments de texte. */
-GBufferLine *g_buffer_line_new(const mrange_t *, BufferLineColumn);
-
-/* Indique la zone mémoire où se situe la ligne. */
-const mrange_t *g_buffer_line_get_range(const GBufferLine *);
+GBufferLine *g_buffer_line_new(BufferLineColumn);
/* Construit le tronc commun d'une ligne autour de sa position. */
void g_buffer_line_fill_phys(GBufferLine *, size_t, MemoryDataSize, const vmpa2t *);
@@ -155,17 +152,6 @@ void g_buffer_line_remove_flag(GBufferLine *, BufferLineFlags);
void g_buffer_line_export(GBufferLine *, buffer_export_context *, BufferExportType, const bool *);
-/* Petite aide pour la détection de commentaire */
-#define g_buffer_line_has_comment(ln) \
- ({ \
- bool __result; \
- __result = g_buffer_line_has_text(ln, BLC_COMMENTS, BLC_COUNT); \
- __result |= (g_buffer_line_get_merge_start(ln) == BLC_DISPLAY \
- && !(g_buffer_line_get_flags(ln) & BLF_IS_LABEL)); \
- __result; \
- })
-
-
/* ----------------------- MANIPULATION DES LARGEURS REQUISES ----------------------- */