button.signal_connect("enter-notify-event") {print "hello "}
button.signal_connect("enter-notify-event") {print "world\n"}
The above does what I expect it to do (ie. when I scroll over the button it prints "Hello World" )
button.signal_connect("enter-notify-event") { print "Hello ";[]}
button.signal_connect("enter-notify-event") { print "World\n";[]}
However this code will not perform the second event (nor any subsequent) - When I scroll over the button it prints "Hello " only (not "World\n"). This seems to be because ending the proc performed by the signal in an Array will somehow stop the second signal_connect from performing its associated Proc.
Using Ruby 1.8.6 and ruby-gnome2-0.16.0-1-i386-mswin32.exe (2007-02-12)
This is not a bug.
You should return false value (it means that "nil" or "false" in Ruby) to continue calling associated Procs.
See also: http://developer.gnome.org/gtk/stable/GtkWidget.html#GtkWidget-enter-notify-event