本文介绍了在jQuery中,当同时使用resizable()和draggable()时,如何解决收容漏洞?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在jQuery中,如何同时使用resizable()和draggable()来解决收容错误?如果在同一对象上使用可拖动对象,则似乎可调整大小的容器的左偏移量和上偏移量似乎有问题.我在Google上进行了查询,有几个人遇到了同样的问题,但是没有答案.如果有人可以帮助,那就太好了,这真让我发疯!!

In jQuery, How do you fix containment bug when using resizable() and draggable() simultaneously? It seems as though the left offset and top offset of the containment for resizable is buggy if you use draggable on the same object. I have looked this up on google and a few people had the same problem, but no answers. If anyone could help it would be great, this is driving me nuts!!

这里有一个例子: http://www.fissiondesigns.com/simon/

尝试调整图像上框的大小.谢谢!

Try resizing one of boxes on the image. Thanks!

推荐答案

看看这个错误.最后一条评论讨论了一个修复程序,因此您可以尝试一下,看看它是否有帮助.它讨论了顶部/左侧位置的问题.使用可滚动div中的可调整大小时,我遇到了类似的问题,这可以解决我的问题(使用1.7.3).

Have a look at this bug. The last comment discusses a fix, so you might try it and see if it helps. It discusses an issue with top/left positioning. I had a similar issue using resizable within a scrollable div and this fixed the problem for my use (using 1.7.3).

ui.resizable-滚动跳转

这篇关于在jQuery中,当同时使用resizable()和draggable()时,如何解决收容漏洞?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-19 12:44