hey all,
im having a problem:
var a = Class.create({
initialize: function(s) {
this.s = s;
$('some_element').observe('keyup',handler);
},
handler: function(event)
{
console.log(this.s);
}
});
this is just a quick example of the problem, not the actual code im
using.
for some reason, the reference to this.s, is not being passed to
handler().
i get console output "undefined", iv done alot of OOP in my time, and
i cant see why this isnt working,
any help would be great!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---