diff options
Diffstat (limited to 'src/analysis/db/items/bookmark.c')
-rw-r--r-- | src/analysis/db/items/bookmark.c | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/src/analysis/db/items/bookmark.c b/src/analysis/db/items/bookmark.c index 8c15e5a..0f985d6 100644 --- a/src/analysis/db/items/bookmark.c +++ b/src/analysis/db/items/bookmark.c @@ -141,9 +141,6 @@ static void g_bookmark_collection_finalize(GBookmarkCollection *); /* Crée la table des signets dans une base de données. */ static bool g_bookmark_collection_create_db_table(const GBookmarkCollection *, sqlite3 *); -/* Détermine si un élément est déjà présent ou non. */ -static GDbItem *g_bookmark_collection_has_key(GBookmarkCollection *, va_list); - /* ---------------------------------------------------------------------------------- */ @@ -788,7 +785,6 @@ static void g_bookmark_collection_class_init(GBookmarkCollectionClass *klass) collec = G_DB_COLLECTION_CLASS(klass); collec->create_table = (collec_create_db_table_fc)g_bookmark_collection_create_db_table; - collec->has_key = (collec_has_key_fc)g_bookmark_collection_has_key; } @@ -920,52 +916,3 @@ static bool g_bookmark_collection_create_db_table(const GBookmarkCollection *col return (ret == SQLITE_OK); } - - -/****************************************************************************** -* * -* Paramètres : collec = ensemble d'éléments à consulter. * -* ap = clef identifiant de manière unique un élément. * -* * -* Description : Détermine si un élément est déjà présent ou non. * -* * -* Retour : Elément trouvé ou NULL si aucun. * -* * -* Remarques : - * -* * -******************************************************************************/ - -static GDbItem *g_bookmark_collection_has_key(GBookmarkCollection *collec, va_list ap) -{ - GDbItem *result; /* Bilan à retourner */ - vmpa2t *ref; /* Adresse de référence */ - GList *items; /* Eléments déjà en place */ - GList *iter; /* Boucle de parcours */ - GDbBookmark *bm; /* Signet à consulter */ - - result = NULL; - - ref = va_arg(ap, vmpa2t *); - -#if 0 - items = g_db_collection_get_items(G_DB_COLLECTION(collec)); - - for (iter = g_list_first(items); iter != NULL && result == NULL; iter = g_list_next(iter)) - { - bm = G_DB_BOOKMARK(iter->data); - - if (cmp_vmpa(&bm->addr, ref) != 0) - - /** - * Un verrou est sensé être posé, donc il n'y a pas besoin - * de toucher au décompte des références car l'élément trouvé - * ne peut pas être supprimé. - */ - result = G_DB_ITEM(bm); - - } -#endif - - return result; - -} |