diff options
Diffstat (limited to 'js')
-rw-r--r-- | js/functions.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/js/functions.js b/js/functions.js index 6d2a58294..0b0b475c6 100644 --- a/js/functions.js +++ b/js/functions.js @@ -1340,6 +1340,7 @@ function selectTableRows(id, mode) { for (var i = 0; i < rows.length; i++) { var row = rows[i]; var cb = false; + var dcb = false; if (row.id && row.className) { var bare_id = row.id.replace(/^[A-Z]*?-/, ""); @@ -1352,27 +1353,33 @@ function selectTableRows(id, mode) { input.id.match(bare_id)) { cb = input; + dcb = dijit.getEnclosingWidget(cb); break; } } - if (cb) { + if (cb || dcb) { var issel = row.hasClassName("Selected"); if (mode == "all" && !issel) { row.addClassName("Selected"); cb.checked = true; + if (dcb) dcb.set("checked", true); } else if (mode == "none" && issel) { row.removeClassName("Selected"); cb.checked = false; + if (dcb) dcb.set("checked", false); + } else if (mode == "invert") { if (issel) { row.removeClassName("Selected"); cb.checked = false; + if (dcb) dcb.set("checked", false); } else { row.addClassName("Selected"); cb.checked = true; + if (dcb) dcb.set("checked", true); } } } |