Signal & object

Hello,

I want to use signal (as in Gtk, not system signal) for some of my
objects.
And I would like to know if there’s any other way than inherited from
GLib::Object to be able to define some signal for my own object ?

I’ve got the following:

class Score < GLib::Object
type_register
signal_new( ‘value_changed’ ,
GLib::Signal::RUN_FIRST,
nil,
GLib::Type[‘void’],
Integer )

def initialize
    super()
end

end

And I want to get rid of all the GLib::Object stuff because I do not
really see
how it could be usefull in my case (except for signal :wink:

Is there any way … I’ve seen something about ‘GLib::Instantiatable’
but Ive
not find any sample or tutorial for using it.

ANy hint/help please ?
Thanks a lot.

±-------------------+

  • Laurent Marzullo

Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs