Hi Eloy, This is great work. I will introduce this API as discussed, when I will fix RubyGems. I started working on this, currently net/http is broken due to the new String changes. BTW, does rspec work nice with MacRuby trunk? I would expect at least some breakage :) Laurent On May 4, 2008, at 10:22 AM, Eloy Duran wrote:
Oh and the current code, not much, is available at: http://github.com/alloy/macruby_rubycocoa_layer/tree/master
On 4 mei 2008, at 19:20, Eloy Duran wrote:
I've started work on a RubyCocoa layer for MacRuby (still very naive).
Like already discussed with Laurent, an API to be able to call the superclass implementation of a method will be necessary for super_foo style methods to work. Imagine this code:
class Foo < OSX::NSObject def init self if super_init end end
Something like this will be needed:
class OSX::NSObject def method_missing(mname, *args, &block) if superclass_method?(mname) # convert mname to selector super_send(selector, *args) # <- #super_send (or something like it) should be able to send a message to the superclasses implementation. else original_method_missing(mname, *args, &block) end end end
I hope this is clear enough?
Cheers, Eloy
_______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo/macruby-devel