[glade3/signal-tree-model] glade-signal-editor: Adapt to GladeSignal changes



commit dab54af2bab031031b75d4a8f9306a80c754daba
Author: Johannes Schmid <jhs gnome org>
Date:   Fri Jan 7 19:02:28 2011 +0100

    glade-signal-editor: Adapt to GladeSignal changes

 gladeui/glade-signal-editor.c |   11 +++++------
 gladeui/glade-signal-model.c  |    2 +-
 2 files changed, 6 insertions(+), 7 deletions(-)
---
diff --git a/gladeui/glade-signal-editor.c b/gladeui/glade-signal-editor.c
index 98f3c8f..e5d15dc 100644
--- a/gladeui/glade-signal-editor.c
+++ b/gladeui/glade-signal-editor.c
@@ -98,8 +98,6 @@ on_handler_edited (GtkCellRendererText* renderer,
 				/* change an existing signal handler */
 				GladeSignal* old_signal;
 				GladeSignal* new_signal;
-
-				g_message ("Changing handler!");
 				
 				gtk_tree_model_get (self->priv->model,
 				                    &iter,
@@ -132,17 +130,18 @@ on_handler_edited (GtkCellRendererText* renderer,
 		else
 		{
 			GladeSignal* signal;
+			GladeSignal* dummy;
 			gchar* name;
-
-			g_message ("Adding handler!");
 			
 			/* Get the signal name */
 			gtk_tree_model_get (self->priv->model, &iter,
-			                    GLADE_SIGNAL_COLUMN_NAME, &name, 
+			                    GLADE_SIGNAL_COLUMN_NAME, &name,
+			                    GLADE_SIGNAL_COLUMN_SIGNAL, &dummy,
 			                    -1);
 			
 			/* Add a new signal handler */
-			signal = glade_signal_new (name, handler, NULL, FALSE, FALSE);
+			signal = glade_signal_new (glade_signal_get_class (dummy),
+			                           handler, NULL, FALSE, FALSE);
 			glade_command_add_signal (self->priv->widget, signal);
 
 			/* Select next column */
diff --git a/gladeui/glade-signal-model.c b/gladeui/glade-signal-model.c
index de69939..e416a17 100644
--- a/gladeui/glade-signal-model.c
+++ b/gladeui/glade-signal-model.c
@@ -278,7 +278,7 @@ glade_signal_model_get_dummy_handler (GladeSignalModel* model, GladeSignalClass*
 
 	if (!signal)
 	{
-		signal = glade_signal_new (glade_signal_class_get_name (sig_class),
+		signal = glade_signal_new (sig_class,
 		                           HANDLER_DEFAULT,
 		                           USERDATA_DEFAULT,
 		                           FALSE,



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