For the following messages, node stands for a tree node or a reference to one and root stands for a tree box or a reference to one.
Caution: If you send a root node that contains one or more nodes with the Set Node Select Script defining a collapse message, then macOS runs the script twice. Windows doesn’t run the script. This behavior on macOS doesn’t just affect increments. Any script runs twice. It will print to the log twice, create a column twice, try to delete something twice, and so on.
– In a single-item tree, the currently selected tree node or Empty is returned.
– Table 3.1 shows the results for a Tree Box() that contains the MultiSelect argument.
Items Selected in Tree |
Result |
---|---|
no items selected |
empty |
single item selected |
list of one tree node |
multiple items selected |
list of selected tree nodes |
Notes:
• On Windows, the Set Selected message expands all nodes between the selected node or nodes and the root of the tree; items that are selected deep within the tree are shown. The expansion state does not change for nodes that were previously selected.
• On macOS, the Set Selected message does not change the tree expansion state.