diff options
Diffstat (limited to 'include/ui.hpp')
| -rw-r--r-- | include/ui.hpp | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/include/ui.hpp b/include/ui.hpp index cdffa58..d6c5fad 100644 --- a/include/ui.hpp +++ b/include/ui.hpp @@ -17,6 +17,7 @@ #pragma once #include "imgui.h" +#include "administration.hpp" #define STATUS_TEXT_LEN 64 #define STATUS_DURATION 4.0f @@ -61,8 +62,6 @@ typedef struct extern ImFont* fontBold; extern ImFont* fontBig; -void ui_helper_draw_required_tag(); - ui_status ui_get_status(); void ui_set_status_loading(bool loading); void ui_set_status_error(const char* txt); @@ -94,4 +93,17 @@ void ui_destroy_expenses(); void ui_destroy_earnings(); // Custom imgui widgets. -int TextInputWithAutocomplete(const char* label, const char* hint, char* buffer, size_t buf_size, char** suggestions, int suggestion_count);
\ No newline at end of file +namespace ImGui +{ + int TextInputWithAutocomplete(const char* hint, char* buffer, size_t buf_size, char** suggestions, int suggestion_count, bool has_error); + + void FormContactAutocomplete(contact* buffer, bool has_error); + void FormInputTextWithErrorHint(const char* hint, void* data, char* buffer, size_t buf_size, bool has_error); + void FormCountryCombo(void* data, char* buffer, size_t buf_size); + void FormContactTypeCombo(contact_type* type); + void FormCostCenterCombo(char* costcenter_id); + void FormProjectCombo(char* project_id); + void FormTaxRateCombo(char* tax_rate_id, char* orig_country, char* dest_country); + bool FormCurrencyCombo(char* currency); + void FormToggleCombo(bool *buffer, char* option1, char* option2); +}
\ No newline at end of file |
