diff options
| author | Aldrik Ramaekers <aldrikboy@gmail.com> | 2025-09-13 08:54:05 +0200 |
|---|---|---|
| committer | Aldrik Ramaekers <aldrikboy@gmail.com> | 2025-09-13 08:54:05 +0200 |
| commit | fb1ae39f1abe0dd0335489451e09a24e2336e606 (patch) | |
| tree | 8bd482a824c11b67581679e6a445a39e11b607e7 /src/ui/ui_main.cpp | |
| parent | 5159a53e58cd4b3652ce6255856d50e15c275f80 (diff) | |
handle file saving through administration callbacks
Diffstat (limited to 'src/ui/ui_main.cpp')
| -rw-r--r-- | src/ui/ui_main.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/ui/ui_main.cpp b/src/ui/ui_main.cpp index bc02243..b245d88 100644 --- a/src/ui/ui_main.cpp +++ b/src/ui/ui_main.cpp @@ -4,6 +4,7 @@ #include "locales.hpp" #include "tinyfiledialogs.h" #include "administration_writer.hpp" +#include "administration_reader.hpp" static main_state ui_state = main_state::UI_END; void (*drawcalls[main_state::UI_END])(void) = { @@ -49,8 +50,6 @@ void ui_set_state(main_state state) if (setupcalls[ui_state]) setupcalls[ui_state](); } -void create_new_administration(); - void ui_draw_main() { if (ui_state == main_state::UI_END) ui_set_state(main_state::UI_START); @@ -60,7 +59,7 @@ void ui_draw_main() { if (ImGui::BeginMenu("File")) { - if (ImGui::MenuItem("New")) { create_new_administration(); } + if (ImGui::MenuItem("New")) { administration_reader_open_new(); } if (ImGui::MenuItem("Open")) { /* Handle Save */ } ImGui::EndMenu(); |
