aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/draggable/draggable_options.js
diff options
context:
space:
mode:
authorMike Sherov <mike.sherov@gmail.com>2013-10-29 18:35:42 -0400
committerMike Sherov <mike.sherov@gmail.com>2013-12-03 10:08:12 -0500
commit44b2180782df6ef3324789324fcf3f98b85784a0 (patch)
treeb33d1da4ca66804d116f8a00be258f5b4c5df818 /tests/unit/draggable/draggable_options.js
parent77bf202e58a2e6bd505a3013812e4dc217bf7c8a (diff)
downloadjquery-ui-44b2180782df6ef3324789324fcf3f98b85784a0.tar.gz
jquery-ui-44b2180782df6ef3324789324fcf3f98b85784a0.zip
Draggable: normalize lookups for rootNodes when to bust scroll cache. Fixes #9379 - Draggable: position bug in scrollable div
Core: update scrollParent() to support all current supported browsers.
Diffstat (limited to 'tests/unit/draggable/draggable_options.js')
-rw-r--r--tests/unit/draggable/draggable_options.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/unit/draggable/draggable_options.js b/tests/unit/draggable/draggable_options.js
index ea52eb299..11a3c6840 100644
--- a/tests/unit/draggable/draggable_options.js
+++ b/tests/unit/draggable/draggable_options.js
@@ -377,7 +377,7 @@ test( "containment, account for border", function() {
test( "containment, default, switching after initialization", function() {
expect( 6 );
- var element = $( "#draggable1" ).draggable({ containment: false });
+ var element = $( "#draggable1" ).draggable({ containment: false, scroll: false });
TestHelpers.draggable.testDrag( element, element, -100, -100, -100, -100, "containment: default" );
@@ -692,7 +692,7 @@ test( "helper, default, switching after initialization", function() {
scroll: false
});
- if ( scrollElements.length === 1 && scrollElements[ 1 ] === "#scrollParent" ) {
+ if ( scrollElements.length === 1 && scrollElements[ 0 ] === "#scrollParent" ) {
TestHelpers.draggable.setScrollable( "#main", false );
TestHelpers.draggable.setScrollable( "#scrollParent", true );
}
@@ -867,6 +867,8 @@ test( "scroll, scrollSensitivity, and scrollSpeed", function() {
test( "#6817: auto scroll goes double distance when dragging", function() {
expect( 2 );
+ TestHelpers.draggable.restoreScroll( document );
+
var offsetBefore,
distance = 10,
viewportHeight = $( window ).height(),
@@ -906,6 +908,7 @@ test( "snap, snapMode, and snapTolerance", function() {
snapTolerance = 15,
element = $( "#draggable1" ).draggable({
snap: true,
+ scroll: false,
snapMode: "both",
snapTolerance: snapTolerance
}),
@@ -1028,6 +1031,7 @@ test( "#8459: element can snap to an element that was removed during drag", func
snapTolerance = 15,
element = $( "#draggable1" ).draggable({
snap: true,
+ scroll: false,
snapMode: "both",
snapTolerance: snapTolerance,
start: function() {