did you inject the element into DOM before call getSize() ?

On 10월28일, 오후8시32분, Vortexmind <[EMAIL PROTECTED]> wrote:
> Hi all
> I am creating a drag & drop interface with Mootols Sortables and so
> on ... I've found a strange behaviour in Element.getSize() function.
> As my D&D panels can be also resized, when I create the original panel
> I store original width & height in a variable like this:
>
>         this._o_width = this._domEl.getSize().x;
>         this._o_height = this._domEl.getSize().y;
>
> I'm inside my class, and this._domEl is actually a new Element('div')
> I've created above these lines.
> I have then a function (on Resize complete) which checks the new
> dimensions after resize, and resets them to original ones if they are
> too small.
>
> My problem is : sometimes the 'default resize' go completly wrong, as
> original dimensions are odd numbers. Debugging with 'console.log' tell
> me that once an then these values are initialized with bad values, and
> sometimes not, just by reloading same page again and again the browser
> (Firefox with Firebug).
>
> So, is there any issue with these functions? or probably I am doing
> something wrong?

Reply via email to