]> source.dussan.org Git - jquery-ui.git/commitdiff
sortable: fixed containment option
authorPaul Bakaus <paul.bakaus@googlemail.com>
Mon, 26 May 2008 11:29:02 +0000 (11:29 +0000)
committerPaul Bakaus <paul.bakaus@googlemail.com>
Mon, 26 May 2008 11:29:02 +0000 (11:29 +0000)
ui/source/ui.sortable.js

index aa44faf18377fe44b42a0650e39bcd94ce907ccf..24339476d46086f8153e252f936ba437d89198a7 100644 (file)
                                        var co = $(o.containment).offset();\r
                                        \r
                                        this.containment = [\r
-                                               co.left + (parseInt($(ce).css("borderLeftWidth"),10) || 0) - this.offset.relative.left - this.offset.parent.left,\r
-                                               co.top + (parseInt($(ce).css("borderTopWidth"),10) || 0) - this.offset.relative.top - this.offset.parent.top,\r
-                                               co.left+Math.max(ce.scrollWidth,ce.offsetWidth) - (parseInt($(ce).css("borderLeftWidth"),10) || 0) - this.offset.relative.left - this.offset.parent.left - this.helperProportions.width - this.margins.left - (parseInt(this.currentItem.css("marginRight"),10) || 0),\r
-                                               co.top+Math.max(ce.scrollHeight,ce.offsetHeight) - (parseInt($(ce).css("borderTopWidth"),10) || 0) - this.offset.relative.top - this.offset.parent.top - this.helperProportions.height - this.margins.top - (parseInt(this.currentItem.css("marginBottom"),10) || 0)\r
+                                               co.left + (parseInt($(ce).css("borderLeftWidth"),10) || 0) - this.offset.parent.left,\r
+                                               co.top + (parseInt($(ce).css("borderTopWidth"),10) || 0) - this.offset.parent.top,\r
+                                               co.left+Math.max(ce.scrollWidth,ce.offsetWidth) - (parseInt($(ce).css("borderLeftWidth"),10) || 0) - this.offset.parent.left - this.helperProportions.width - this.margins.left - (parseInt(this.currentItem.css("marginRight"),10) || 0),\r
+                                               co.top+Math.max(ce.scrollHeight,ce.offsetHeight) - (parseInt($(ce).css("borderTopWidth"),10) || 0) - this.offset.parent.top - this.helperProportions.height - this.margins.top - (parseInt(this.currentItem.css("marginBottom"),10) || 0)\r
                                        ];\r
                                }\r
                        }\r