[gtksourceview/wip/completion-model: 18/19] CompletionModel: remove providers-changed signal



commit 657befedcc4a0a9604ea41cfd26f3288c9cc6093
Author: SÃbastien Wilmet <swilmet gnome org>
Date:   Tue Jan 22 15:51:03 2013 +0100

    CompletionModel: remove providers-changed signal
    
    It was used only for updating a label, but updating it at the end of the
    population is enough.

 gtksourceview/gtksourcecompletion.c      |   12 ------------
 gtksourceview/gtksourcecompletionmodel.c |   21 ---------------------
 2 files changed, 0 insertions(+), 33 deletions(-)
---
diff --git a/gtksourceview/gtksourcecompletion.c b/gtksourceview/gtksourcecompletion.c
index bf00d5c..4a95e7b 100644
--- a/gtksourceview/gtksourcecompletion.c
+++ b/gtksourceview/gtksourcecompletion.c
@@ -2840,13 +2840,6 @@ selection_func (GtkTreeSelection    *selection,
 }
 
 static void
-on_providers_changed (GtkSourceCompletionModel *model,
-                      GtkSourceCompletion      *completion)
-{
-	update_selection_label (completion);
-}
-
-static void
 info_button_style_updated (GtkWidget           *button,
                            GtkSourceCompletion *completion)
 {
@@ -2883,11 +2876,6 @@ replace_model (GtkSourceCompletion *completion)
 
 	gtk_source_completion_model_set_show_headers (completion->priv->model_proposals,
 				                      completion->priv->show_headers);
-
-	g_signal_connect (completion->priv->model_proposals,
-	                  "providers-changed",
-	                  G_CALLBACK (on_providers_changed),
-	                  completion);
 }
 
 static void
diff --git a/gtksourceview/gtksourcecompletionmodel.c b/gtksourceview/gtksourcecompletionmodel.c
index df15e3f..5832f74 100644
--- a/gtksourceview/gtksourcecompletionmodel.c
+++ b/gtksourceview/gtksourcecompletionmodel.c
@@ -67,14 +67,6 @@ struct _GtkSourceCompletionModelPrivate
 	guint show_headers : 1;
 };
 
-enum
-{
-	PROVIDERS_CHANGED,
-	NUM_SIGNALS
-};
-
-static guint signals[NUM_SIGNALS] = {0,};
-
 static void tree_model_iface_init (gpointer g_iface, gpointer iface_data);
 
 G_DEFINE_TYPE_WITH_CODE (GtkSourceCompletionModel,
@@ -700,17 +692,6 @@ gtk_source_completion_model_class_init (GtkSourceCompletionModelClass *klass)
 
 	object_class->dispose = gtk_source_completion_model_dispose;
 
-	signals[PROVIDERS_CHANGED] =
-		g_signal_new ("providers-changed",
-		              G_TYPE_FROM_CLASS (klass),
-		              G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
-		              G_STRUCT_OFFSET (GtkSourceCompletionModelClass, providers_changed),
-		              NULL,
-		              NULL,
-		              g_cclosure_marshal_VOID__VOID,
-		              G_TYPE_NONE,
-		              0);
-
 	g_type_class_add_private (object_class, sizeof(GtkSourceCompletionModelPrivate));
 }
 
@@ -780,8 +761,6 @@ create_provider_info (GtkSourceCompletionModel    *model,
 		add_header (provider_node);
 	}
 
-	g_signal_emit (model, signals[PROVIDERS_CHANGED], 0);
-
 	return provider_node;
 }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]