summaryrefslogtreecommitdiff
path: root/ted.h
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2021-01-06 13:35:31 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2021-01-06 13:35:31 -0500
commit9e055b2e25455fc4fa0376495ccc9335059f3131 (patch)
treeef9e2362dece86193c07d8e1fcf40923b8a8caca /ted.h
parent306505e714b7caf146b8ec8386b407d57555563d (diff)
start open menu
Diffstat (limited to 'ted.h')
-rw-r--r--ted.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/ted.h b/ted.h
index 0f5b72c..8c475a9 100644
--- a/ted.h
+++ b/ted.h
@@ -65,10 +65,19 @@ typedef struct {
BufferEdit *redo_history; // dynamic array of redo history
} TextBuffer;
+ENUM_U16 {
+ MENU_NONE,
+ MENU_OPEN
+} ENUM_U16_END(Menu);
+
typedef struct Ted {
Font *font;
TextBuffer *active_buffer;
+ // while a menu or something is open, there is no active buffer. when the menu is closed,
+ // the old active buffer needs to be restored. that's what this stores.
+ TextBuffer *prev_active_buffer;
Settings settings;
+ Menu menu;
KeyAction key_actions[KEY_COMBO_COUNT];
char error[256];
} Ted;