#367: Error in color.rb
--------------------------------+-------------------------------------------
Reporter: i.scr...@… | Owner: lsansone...@…
Type: defect | Status: new
Priority: blocker | Milestone: MacRuby 0.5
Component: MacRuby | Keywords: Hotcocoa Color Error
--------------------------------+-------------------------------------------
The file color.rb inside the hotcocoa/graphics directors is using a wrong
class method!
Following code has to be changed:
COLORNAMES.each_key do |name|
(class << self; self; end).define_method(name) do
named(name)
end
end
In this case define_singleton_method is the way to go.
COLORNAMES.each_key do |name|
(class << self; self; end).define_singleton_method(name) do
named(name)
end
end
Tom Fuerstner
--
Ticket URL: <http://www.macruby.org/trac/ticket/367>
MacRuby <http://macruby.org/>
_______________________________________________
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel