Toolbar manage the concept of single and multiple actions over the mindmap.

This commit is contained in:
Paulo Gustavo Veiga
2012-05-20 14:54:35 -03:00
parent a4e6325b12
commit 93da41dcf5
2 changed files with 19 additions and 12 deletions

View File

@@ -151,17 +151,24 @@ function updateToolbar() {
$("#mindmapListTable tbody input:not(:checked)").parent().parent().removeClass('row-selected');
var inputs = $("#mindmapListTable tbody input:checked");
var selected = inputs.length > 0;
if (selected) {
$("#actionsBtn").show();
$("#deleteBtn").show();
$("#infoBtn").show();
} else {
$("#actionsBtn").hide();
$("#deleteBtn").hide();
$("#infoBtn").hide();
$("#buttonsToolbar .act-multiple").hide();
$("#buttonsToolbar .act-single").hide();
console.log($("#buttonsToolbar .act-multiple"));
if (inputs.length > 0) {
if (inputs.length == 1) {
$("#buttonsToolbar .act-single").show();
$("#buttonsToolbar .act-multiple").show();
} else {
$("#buttonsToolbar .act-multiple").show();
}
}
}