summaryrefslogtreecommitdiff
path: root/misc/tabledrag.js
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-03-10 20:31:59 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-03-10 20:31:59 +0000
commit2e460ac3b4cae4e9e265980d5e9f7c2c6e03c3ef (patch)
treed1078108b8aa44bb9fa40972c83eb26ee678bd1f /misc/tabledrag.js
parent632ae14d9cd4ed60c6fe365ca15f1d3904bc165b (diff)
downloadbrdo-2e460ac3b4cae4e9e265980d5e9f7c2c6e03c3ef.tar.gz
brdo-2e460ac3b4cae4e9e265980d5e9f7c2c6e03c3ef.tar.bz2
#737596 by casey: Fixed tabledrag.js: ('.indentation', testCell).get(1) is undefined.
Diffstat (limited to 'misc/tabledrag.js')
-rw-r--r--misc/tabledrag.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/misc/tabledrag.js b/misc/tabledrag.js
index c671c31ed..11ec74629 100644
--- a/misc/tabledrag.js
+++ b/misc/tabledrag.js
@@ -73,10 +73,10 @@ Drupal.tableDrag = function (table, tableSettings) {
// manually append 2 indentations in the first draggable row, measure
// the offset, then remove.
var indent = Drupal.theme('tableDragIndentation');
- // Match immediate children of the parent element to allow nesting.
- var testCell = $('> tbody > tr.draggable:first td:first, > tr.draggable:first td:first', table).prepend(indent).prepend(indent);
+ var testRow = $('<tr/>').addClass('draggable').appendTo(table);
+ var testCell = $('<td/>').appendTo(testRow).prepend(indent).prepend(indent);
this.indentAmount = $('.indentation', testCell).get(1).offsetLeft - $('.indentation', testCell).get(0).offsetLeft;
- $('.indentation', testCell).slice(0, 2).remove();
+ testRow.remove();
}
// Make each applicable row draggable.