Ticket #367 (closed defect: invalid)
Error in color.rb
| Reported by: | i.script@… | Owned by: | rich@… |
|---|---|---|---|
| Priority: | blocker | Milestone: | MacRuby 0.5 |
| Component: | MacRuby | Keywords: | Hotcocoa Color Error |
| Cc: |
Description
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
Change History
Note: See
TracTickets for help on using
tickets.

