diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2021-01-06 13:35:31 -0500 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2021-01-06 13:35:31 -0500 |
commit | 9e055b2e25455fc4fa0376495ccc9335059f3131 (patch) | |
tree | ef9e2362dece86193c07d8e1fcf40923b8a8caca /ted-base.c | |
parent | 306505e714b7caf146b8ec8386b407d57555563d (diff) |
start open menu
Diffstat (limited to 'ted-base.c')
-rw-r--r-- | ted-base.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -82,3 +82,15 @@ static void ted_load_font(Ted *ted) { ted_seterr(ted, "Couldn't find font file. There is probably a problem with your ted installation."); } } + +static void ted_menu_open(Ted *ted, Menu menu) { + ted->menu = menu; + ted->prev_active_buffer = ted->active_buffer; + ted->active_buffer = NULL; +} + +static void ted_menu_close(Ted *ted, bool restore_prev_active_buffer) { + ted->menu = MENU_NONE; + if (restore_prev_active_buffer) ted->active_buffer = ted->prev_active_buffer; + ted->prev_active_buffer = NULL; +} |