# mode_tree_collapse_current

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/mode-tree.c#L390
- **Page:** https://libtmux.org/en/tmux/latest/reference/c-function-mode_tree_collapse_current/

```c
void mode_tree_collapse_current(struct mode_tree_data *mtd)
```

## Parameters

- `mtd` (`struct mode_tree_data *`)

## Called by

- [`window_customize_reset_key`](/en/tmux/latest/reference/c-function-window-customize-c-window_customize_reset_key/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-customize.c#L1339)
- [`window_customize_unset_key`](/en/tmux/latest/reference/c-function-window-customize-c-window_customize_unset_key/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-customize.c#L1319)

## Calls

- [`mode_tree_build`](/en/tmux/latest/reference/c-function-mode_tree_build/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/mode-tree.c#L394)

## Referenced declarations

- [`mode_tree_data.current`](/en/tmux/latest/reference/c-struct-mode_tree_data-current/) (attribute)
- [`mode_tree_item.expanded`](/en/tmux/latest/reference/c-struct-mode_tree_item-expanded/) (attribute)
- [`mode_tree_line.item`](/en/tmux/latest/reference/c-struct-mode_tree_line-item/) (attribute)
- [`mode_tree_data.line_list`](/en/tmux/latest/reference/c-struct-mode_tree_data-line_list/) (attribute)
- [`mode_tree_data`](/en/tmux/latest/reference/c-struct-mode_tree_data/) (struct)
