Created
January 4, 2014 19:00
-
-
Save egrajeda/8259186 to your computer and use it in GitHub Desktop.
Patch for http://bugs.jqueryui.com/ticket/9727
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 79f8b7ed80b4f52cfd398021441428b3dd095e4b Mon Sep 17 00:00:00 2001 | |
From: Eduardo Grajeda <tatofoo@gmail.com> | |
Date: Sat, 4 Jan 2014 12:56:36 -0600 | |
Subject: [PATCH] Sortable: cancel() now doesn't ignore comment nodes | |
Fixes #9727 | |
--- | |
ui/jquery.ui.sortable.js | 2 +- | |
1 file changed, 1 insertion(+), 1 deletion(-) | |
diff --git a/ui/jquery.ui.sortable.js b/ui/jquery.ui.sortable.js | |
index 4ba2576..1a41d71 100644 | |
--- a/ui/jquery.ui.sortable.js | |
+++ b/ui/jquery.ui.sortable.js | |
@@ -205,7 +205,7 @@ $.widget("ui.sortable", $.ui.mouse, { | |
(o.cursorAt && this._adjustOffsetFromHelper(o.cursorAt)); | |
//Cache the former DOM position | |
- this.domPosition = { prev: this.currentItem.prev()[0], parent: this.currentItem.parent()[0] }; | |
+ this.domPosition = { prev: this.currentItem[0].previousSibling, parent: this.currentItem.parent()[0] }; | |
//If the helper is not the original, hide the original so it's not playing any role during the drag, won't cause anything bad this way | |
if(this.helper[0] !== this.currentItem[0]) { | |
-- | |
1.8.1.2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment