Patch for deprecated gtk_signal_new() in gtk/gtknotebook.c



I spotted a function marked deprecated in gtknotebook.c, so I took a guess
at the fix. The patch is attached.
Index: gtknotebook.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtknotebook.c,v
retrieving revision 1.112
diff -u -r1.112 gtknotebook.c
--- gtknotebook.c	2001/12/12 20:10:52	1.112
+++ gtknotebook.c	2001/12/26 01:39:13
@@ -433,14 +433,15 @@
 								 G_PARAM_READWRITE));
   
   notebook_signals[SWITCH_PAGE] =
-    gtk_signal_new ("switch_page",
-		    GTK_RUN_LAST,
-		    GTK_CLASS_TYPE (object_class),
-		    GTK_SIGNAL_OFFSET (GtkNotebookClass, switch_page),
-		    _gtk_marshal_VOID__POINTER_UINT,
-		    GTK_TYPE_NONE, 2,
-		    GTK_TYPE_POINTER,
-		    GTK_TYPE_UINT);
+    g_signal_new ("switch_page",
+		  G_TYPE_FROM_CLASS (object_class),
+		  G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
+		  G_STRUCT_OFFSET (GtkNotebookClass, switch_page),
+		  NULL, NULL,
+		  _gtk_marshal_VOID__POINTER_UINT,
+		  G_TYPE_NONE, 2,
+		  G_TYPE_POINTER,
+		  G_TYPE_UINT);
   notebook_signals[FOCUS_TAB] = 
     g_signal_new ("focus_tab",
                   G_TYPE_FROM_CLASS (object_class),


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