Hi,
I have 2 divs, a parent and a children which is draggable.
Parent is in overflow hidden and child is bigger (larger) than its
parent.
I want to constrain on its x axys (that the easiest part) and to be
between 0 and - width, it's mean that child will be draggable until
its left side reach the parent left side and its right side reach
parent right side.
I tried constainment and grid but with no results.
I'm currently trying to do (table.w is the computed width of the
chidren) :
if($(this).css('left') > 0)
{
$(this).css('left',0);
}
if($(this).css('left') < (table.w * -1))
{
$(this).css('left', (table.w * -1));
}
It doesn't set this css left to 0 or table.w.
Any ideas, and was it clear ?
Thanks, regards,
David
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"jQuery UI" 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/jquery-ui?hl=en
-~----------~----~----~----~------~----~------~--~---