From b278d242d03ba614779243ec9e9495fc95abea3d Mon Sep 17 00:00:00 2001 From: Aldrik Ramaekers Date: Sun, 5 Oct 2025 15:15:55 +0200 Subject: strops format --- src/ui/ui_contacts.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'src/ui/ui_contacts.cpp') diff --git a/src/ui/ui_contacts.cpp b/src/ui/ui_contacts.cpp index 03fcee0..7d585c9 100644 --- a/src/ui/ui_contacts.cpp +++ b/src/ui/ui_contacts.cpp @@ -14,9 +14,6 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include -#include - #include "strops.hpp" #include "config.hpp" #include "ui.hpp" @@ -163,7 +160,7 @@ static void draw_contact_list() ImGui::TableSetColumnIndex(3); char btn_name[20]; - snprintf(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.view"), i); + strops::format(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.view"), i); if (ImGui::Button(btn_name)) { active_contact = c; current_view_state = ui::view_state::VIEW_EXISTING; @@ -171,14 +168,14 @@ static void draw_contact_list() ImGui::SameLine(); - snprintf(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.change"), i); + strops::format(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.change"), i); if (ImGui::Button(btn_name)) { active_contact = c; current_view_state = ui::view_state::EDIT_EXISTING; } ImGui::SameLine(); - snprintf(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.delete"), i); + strops::format(btn_name, sizeof(btn_name), "%s##%d", locale::get("form.delete"), i); if (ImGui::Button(btn_name)) { selected_for_removal = c; ImGui::OpenPopup("ConfirmDeletePopup"); -- cgit v1.2.3-70-g09d2