Add a docstring to action_toggle_node

This commit is contained in:
Dave Pearson
2023-01-31 12:50:12 +00:00
parent 775165ec12
commit ca224b76ab

View File

@@ -1007,6 +1007,7 @@ class Tree(Generic[TreeDataType], ScrollView, can_focus=True):
self.scroll_to_line(self.cursor_line) self.scroll_to_line(self.cursor_line)
def action_toggle_node(self) -> None: def action_toggle_node(self) -> None:
"""Toggle the expanded state of the target node."""
try: try:
line = self._tree_lines[self.cursor_line] line = self._tree_lines[self.cursor_line]
except IndexError: except IndexError: