ericdfields
2008-Jan-11 22:18 UTC
how do we declare options for (element, source[, options]) syntax?
I''m having trouble understanding option declaration for methods like
clonePosition, whose syntax is thus:
clonePosition(element, source[, options]) -> HTMLElement
I haven''t been able to figure it out. I tried the traditional (element,
{options}) approach, and the method fired no problem but didn''t obey
my options at all:
tooltip.clonePosition(inputElem,{setWidth: "false", setHeight:
"false"});
I''m clearly doing it the wrong way. What''s right?
Thank you.
--~--~---------~--~----~------------~-------~--~----~
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
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---
Nicolás Sanguinetti
2008-Jan-11 22:31 UTC
Re: how do we declare options for (element, source[, options]) syntax?
The method call is ok, pass { setWidth: false, setHeight: false }
The string "false" evaluates to true :)
Best,
-Nicolas
On Jan 11, 2008 8:18 PM, ericdfields
<ericdfields-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:>
> I''m having trouble understanding option declaration for methods
like
> clonePosition, whose syntax is thus:
>
> clonePosition(element, source[, options]) -> HTMLElement
>
> I haven''t been able to figure it out. I tried the traditional
(element,
> {options}) approach, and the method fired no problem but didn''t
obey
> my options at all:
>
> tooltip.clonePosition(inputElem,{setWidth: "false", setHeight:
> "false"});
>
> I''m clearly doing it the wrong way. What''s right?
>
> Thank you.
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
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
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---