2007-07-17 Emmanuele Bassi <ebassi@openedhand.com>
authorEmmanuele Bassi <ebassi@openedhand.com>
Tue, 17 Jul 2007 14:26:15 +0000 (14:26 +0000)
committerEmmanuele Bassi <ebassi@openedhand.com>
Tue, 17 Jul 2007 14:26:15 +0000 (14:26 +0000)
* examples/gtk-clutter-events.c: Remove wrong casting around
the g_signal_connect() argument; this masked a weird memory
corruption bug happening when compiling outside the sources
directory.

ChangeLog
examples/gtk-clutter-events.c

index 0049f94..5c8b483 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2007-07-17  Emmanuele Bassi  <ebassi@openedhand.com>
 
+       * examples/gtk-clutter-events.c: Remove wrong casting around
+       the g_signal_connect() argument; this masked a weird memory
+       corruption bug happening when compiling outside the sources
+       directory.
+
+2007-07-17  Emmanuele Bassi  <ebassi@openedhand.com>
+
        * clutter-gtk/Makefile.am:
        * clutter-gtk.pc.in: Install (and use) a versioned library, to
        match the behaviour of clutter-core and the other integration
index 0649695..c3635ea 100644 (file)
@@ -88,9 +88,9 @@ main (gint argc, gchar **argv)
   ClutterColor   text_color = {0, 0, 0, 255};
 
   clutter_init (&argc, &argv);
+  
   gtk_init (&argc, &argv);
 
-
   /* Create the inital gtk window and widgets, just like normal */
   widget = gtk_window_new (GTK_WINDOW_TOPLEVEL);
   app->window = widget;
@@ -98,8 +98,7 @@ main (gint argc, gchar **argv)
   gtk_window_set_default_size (GTK_WINDOW (widget), 800, 600);
   gtk_window_set_resizable (GTK_WINDOW (widget), FALSE);
   gtk_container_set_border_width (GTK_CONTAINER (widget), 12);
-  g_signal_connect (G_OBJECT (widget), "destroy-event",
-                    G_CALLBACK (gtk_main_quit), NULL);
+  g_signal_connect (widget, "destroy", G_CALLBACK (gtk_main_quit), NULL);
  
   /* Create our layout box */
   vbox = gtk_vbox_new (FALSE, 12);
@@ -109,8 +108,7 @@ main (gint argc, gchar **argv)
   app->gtk_entry = widget;
   gtk_entry_set_text (GTK_ENTRY (widget), "Enter some text");
   gtk_box_pack_start (GTK_BOX (vbox), widget, FALSE, FALSE, 0);
-  g_signal_connect (G_OBJECT (box), "changed",
-                    G_CALLBACK (on_gtk_entry_changed), app);
+  g_signal_connect (widget, "changed", G_CALLBACK (on_gtk_entry_changed), app);
 
   hbox = gtk_hbox_new (FALSE, 12);
   gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE, TRUE, 0);
@@ -152,8 +150,7 @@ main (gint argc, gchar **argv)
   gtk_box_pack_start (GTK_BOX (box), label, TRUE, TRUE, 0);
   button = gtk_spin_button_new_with_range (0, 360, 1);
   gtk_box_pack_start (GTK_BOX (box), button, TRUE, TRUE, 0);
-  g_signal_connect (G_OBJECT (button), "value-changed", 
-                    G_CALLBACK (on_x_changed), app);
+  g_signal_connect (button, "value-changed", G_CALLBACK (on_x_changed), app);
   
   box = gtk_hbox_new (TRUE, 6);
   gtk_box_pack_start (GTK_BOX (vbox), box, FALSE, TRUE, 0);
@@ -161,8 +158,7 @@ main (gint argc, gchar **argv)
   gtk_box_pack_start (GTK_BOX (box), label, TRUE, TRUE, 0);
   button = gtk_spin_button_new_with_range (0, 360, 1);
   gtk_box_pack_start (GTK_BOX (box), button, TRUE, TRUE, 0);
-  g_signal_connect (G_OBJECT (button), "value-changed", 
-                    G_CALLBACK (on_y_changed), app);
+  g_signal_connect (button, "value-changed", G_CALLBACK (on_y_changed), app);
 
   box = gtk_hbox_new (TRUE, 6);
   gtk_box_pack_start (GTK_BOX (vbox), box, FALSE, TRUE, 0);
@@ -170,8 +166,7 @@ main (gint argc, gchar **argv)
   gtk_box_pack_start (GTK_BOX (box), label, TRUE, TRUE, 0);
   button = gtk_spin_button_new_with_range (0, 360, 1);
   gtk_box_pack_start (GTK_BOX (box), button, TRUE, TRUE, 0);
-  g_signal_connect (G_OBJECT (button), "value-changed", 
-                    G_CALLBACK (on_z_changed), app);
+  g_signal_connect (button, "value-changed", G_CALLBACK (on_z_changed), app);
 
   box = gtk_hbox_new (TRUE, 6);
   gtk_box_pack_start (GTK_BOX (vbox), box, FALSE, TRUE, 0);
@@ -180,8 +175,7 @@ main (gint argc, gchar **argv)
   button = gtk_spin_button_new_with_range (0, 255, 1);
   gtk_spin_button_set_value (GTK_SPIN_BUTTON (button), 255);
   gtk_box_pack_start (GTK_BOX (box), button, TRUE, TRUE, 0);
-  g_signal_connect (G_OBJECT (button), "value-changed", 
-                    G_CALLBACK (on_opacity_changed), app);
+  g_signal_connect (button, "value-changed", G_CALLBACK (on_opacity_changed), app);
 
   clutter_actor_show_all (app->stage);
   gtk_widget_show_all (app->window);