ahh *redface*
well i ended up adding it myself, hacky:
if( YAHOO.lang.isString(button.onClick) ) {
buttonEl.onclick = button.onClick;
YAHOO.util.Event.addListener(buttonEl, "click", function(e)
{eval(button.onClick)});
}
this.buttons.push(buttonEl);
On Sep 30, 4:53 pm, "Eric Abouaf" <
eric.abo...@gmail.com> wrote:
> onClick should be a function
>
> ex :
> buttons: [{type: 'submit', value: 'Login'},{type: 'button', value:
> 'New User', onClick: function() { alert(this.value); } }],
>
> This is not really json anymore... :(
> Maybe I'll add an eval if onClick is a string...
>
> 2008/9/30 unomi <
guidebook.in...@gmail.com>