From 418f4dac1246f5e0f406df54e060a443648b457a Mon Sep 17 00:00:00 2001 From: Christian Dywan Date: Fri, 21 Nov 2008 02:46:47 +0100 Subject: [PATCH] Remove unused sokoke completion helpers --- midori/sokoke.c | 25 ------------------------- midori/sokoke.h | 7 ------- 2 files changed, 32 deletions(-) diff --git a/midori/sokoke.c b/midori/sokoke.c index 7ea9b830..2822f5a2 100644 --- a/midori/sokoke.c +++ b/midori/sokoke.c @@ -152,31 +152,6 @@ sokoke_magic_uri (const gchar* uri, return g_strdup (uri); } -void -sokoke_entry_setup_completion (GtkEntry* entry) -{ - /* TODO: The current behavior works only with the beginning of strings - But we want to match "localhost" with "loc" and "hos" */ - GtkEntryCompletion* completion = gtk_entry_completion_new (); - gtk_entry_completion_set_model (completion, - GTK_TREE_MODEL (gtk_list_store_new (1, G_TYPE_STRING))); - gtk_entry_completion_set_text_column (completion, 0); - gtk_entry_completion_set_minimum_key_length (completion, 3); - gtk_entry_set_completion (entry, completion); - /* FIXME: Completion doesn't work well, so it's disabled */ - gtk_entry_completion_set_popup_completion (completion, FALSE); -} - -void -sokoke_entry_append_completion (GtkEntry* entry, const gchar* text) -{ - GtkEntryCompletion* completion = gtk_entry_get_completion (entry); - GtkTreeModel* completion_store = gtk_entry_completion_get_model (completion); - GtkTreeIter iter; - gtk_list_store_insert (GTK_LIST_STORE (completion_store), &iter, 0); - gtk_list_store_set (GTK_LIST_STORE (completion_store), &iter, 0, text, -1); -} - void sokoke_combo_box_add_strings (GtkComboBox* combobox, const gchar* label_first, ...) diff --git a/midori/sokoke.h b/midori/sokoke.h index 3f7d5a71..6e769ed9 100644 --- a/midori/sokoke.h +++ b/midori/sokoke.h @@ -27,13 +27,6 @@ gchar* sokoke_magic_uri (const gchar* uri, KatzeArray* search_engines); -void -sokoke_entry_setup_completion (GtkEntry* entry); - -void -sokoke_entry_append_completion (GtkEntry* entry, - const gchar* text); - typedef enum { SOKOKE_MENU_POSITION_CURSOR = 0, SOKOKE_MENU_POSITION_LEFT,