Its easy to change the code so that all macros are checked (to be deleted) by default.
Edit the "DeleteMacros" macro.
Look for this part:
Code: Select all
<!--Build the input string for the tabs and checkboxes-->
[h,foreach(uniqueGroup, uniqueGroupList),CODE:
{
[macroLabels = listSort(json.get(macrosInGroup, uniqueGroup), "N+")]
[h:inputParams = json.append(inputParams, "group_"+roll.count+"|"+uniqueGroup+"||TAB")]
[h:inputParams = json.append(inputParams, ".|<html><b>Select the Macros you wish to delete. Note: There is no undo!</b></html>||LABEL|SPAN=TRUE")]
[foreach(macroLabel, macroLabels),CODE:
{
[idx = getMacroIndexes(macroLabel)]
[foreach(index, idx): inputParams =if(if(getStrProp(getMacroProps(index),"group")=="", "Top Level", getStrProp(getMacroProps(index),"group")) == uniqueGroup, json.append(inputParams, "macro_"+index+"|0|<html>"+macroLabel+" "+if(getStrProp(getMacroProps(index),"tooltip")=="", "(no tooltip available)", "("+getStrProp(getMacroProps(index),"tooltip")+")")+"</html>|CHECK"), inputParams)]
}]
}]
Change the 0 to a 1 in this line:
Code: Select all
[foreach(index, idx): inputParams =if(if(getStrProp(getMacroProps(index),"group")=="", "Top Level", getStrProp(getMacroProps(index),"group")) == uniqueGroup, json.append(inputParams, "macro_"+index+"|0|<html>"+macroLabel+" "+if(getStrProp(getMacroProps(index),"tooltip")=="", "(no tooltip available)", "("+getStrProp(getMacroProps(index),"tooltip")+")")+"</html>|CHECK"), inputParams)]
That zero ...
[foreach(index, idx): inputParams =if(if(getStrProp(getMacroProps(index),"group")=="", "Top Level", getStrProp(getMacroProps(index),"group")) == uniqueGroup, json.append(inputParams, "macro_"+index+"|
0|<html>"+macroLabel+" "+if(getStrProp(getMacroProps(index),"tooltip")=="", "(no tooltip available)", "("+getStrProp(getMacroProps(index),"tooltip")+")")+"</html>|CHECK"), inputParams)]