]> Pileus Git - ~andy/gtk/commitdiff
if the lookup failed, try to initialize the object class and reattempt the
authorTim Janik <timj@gtk.org>
Sun, 10 Jan 1999 19:05:36 +0000 (19:05 +0000)
committerTim Janik <timj@src.gnome.org>
Sun, 10 Jan 1999 19:05:36 +0000 (19:05 +0000)
1999-01-10  Tim Janik  <timj@gtk.org>

        * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
        to initialize the object class and reattempt the lookup, reported
        by Paolo Molaro <lupus@lettere.unipd.it>.

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtksignal.c

index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 80c56d2bb22ae39f1fe440d5b67edaf8cd1d4289..0b5ece2670256b343142088658b7790c082f0bfc 100644 (file)
@@ -1,3 +1,9 @@
+1999-01-10  Tim Janik  <timj@gtk.org>
+
+       * gtk/gtksignal.c (gtk_signal_lookup): if the lookup failed, try
+       to initialize the object class and reattempt the lookup, reported
+       by Paolo Molaro <lupus@lettere.unipd.it>.
+
 Sat Jan  9 17:36:20 1999  Owen Taylor  <otaylor@redhat.com>
 
        * configure.in (ALL_LINGUAS): Added cs to ALL_LINGUAS.
index 198e3b9ea3668c575542f00e7dd52309fc085305..d3ce62d60ce063e9563db44db95cbb52c81ddc48 100644 (file)
@@ -402,27 +402,38 @@ gtk_signal_lookup (const gchar *name,
                   GtkType      object_type)
 {
   GtkSignalHash hash;
-  
+  GtkType lookup_type;
+  gpointer class = NULL;
+
   g_return_val_if_fail (name != NULL, 0);
   g_return_val_if_fail (gtk_type_is_a (object_type, GTK_TYPE_OBJECT), 0);
   
+ relookup:
+
+  lookup_type = object_type;
   hash.quark = g_quark_try_string (name);
   if (hash.quark)
     {
-      while (object_type)
+      while (lookup_type)
        {
          guint signal_id;
          
-         hash.object_type = object_type;
+         hash.object_type = lookup_type;
          
          signal_id = GPOINTER_TO_UINT (g_hash_table_lookup (gtk_signal_hash_table, &hash));
          if (signal_id)
            return signal_id;
          
-         object_type = gtk_type_parent (object_type);
+         lookup_type = gtk_type_parent (lookup_type);
        }
     }
-  
+
+  if (!class)
+    {
+      class = gtk_type_class (object_type);
+      goto relookup;
+    }
+
   return 0;
 }