gobject/: fully remove gobjectalias hacks
[platform/upstream/glib.git] / gobject / gsignal.c
index c7c1679..df5a37b 100644 (file)
@@ -36,7 +36,7 @@
 #include "gboxed.h"
 #include "gobject.h"
 #include "genums.h"
-#include "gobjectalias.h"
+#include "gobject_trace.h"
 
 
 /**
@@ -1285,7 +1285,7 @@ g_signal_query (guint         signal_id,
  *  %G_SIGNAL_RUN_FIRST or %G_SIGNAL_RUN_LAST.
  * @class_offset: The offset of the function pointer in the class structure
  *  for this type. Used to invoke a class method generically. Pass 0 to
- *  not associate a class method with this signal.
+ *  not associate a class method slot with this signal.
  * @accumulator: the accumulator for this signal; may be %NULL.
  * @accu_data: user data for the @accumulator.
  * @c_marshaller: the function to translate arrays of parameter values to
@@ -1305,6 +1305,11 @@ g_signal_query (guint         signal_id,
  * When registering a signal and looking up a signal, either separator can
  * be used, but they cannot be mixed.
  *
+ * If 0 is used for @class_offset subclasses cannot override the class handler
+ * in their <code>class_init</code> method by doing
+ * <code>super_class->signal_handler = my_signal_handler</code>. Instead they
+ * will have to use g_signal_override_class_handler().
+ *
  * Returns: the signal id
  */
 guint
@@ -1603,6 +1608,8 @@ g_signal_newv (const gchar       *signal_name,
       node->name = g_intern_string (name);
       key.quark = g_quark_from_string (name);
       g_signal_key_bsa = g_bsearch_array_insert (g_signal_key_bsa, &g_signal_key_bconfig, &key);
+
+      TRACE(GOBJECT_SIGNAL_NEW(signal_id, name, itype));
     }
   node->destroyed = FALSE;
   node->test_class_offset = 0;
@@ -3119,7 +3126,9 @@ signal_emit_unlocked_R (SignalNode   *node,
        G_BREAKPOINT ();
     }
 #endif /* G_ENABLE_DEBUG */
-  
+
+  TRACE(GOBJECT_SIGNAL_EMIT(node->signal_id, detail, instance, G_TYPE_FROM_INSTANCE (instance)));
+
   SIGNAL_LOCK ();
   signal_id = node->signal_id;
   if (node->flags & G_SIGNAL_NO_RECURSE)
@@ -3377,7 +3386,9 @@ signal_emit_unlocked_R (SignalNode   *node,
   SIGNAL_UNLOCK ();
   if (accumulator)
     g_value_unset (&accu);
-  
+
+  TRACE(GOBJECT_SIGNAL_EMIT_END(node->signal_id, detail, instance, G_TYPE_FROM_INSTANCE (instance)));
+
   return return_value_altered;
 }
 
@@ -3430,6 +3441,3 @@ g_signal_accumulator_true_handled (GSignalInvocationHint *ihint,
 
 /* --- compile standard marshallers --- */
 #include "gmarshal.c"
-
-#define __G_SIGNAL_C__
-#include "gobjectaliasdef.c"