From 21243ea979a86420fa402d875a0fb4e1acc0e965 Mon Sep 17 00:00:00 2001 From: Green Sky Date: Mon, 1 Jul 2024 14:00:00 +0200 Subject: [PATCH] show contact ID in tooltip --- src/chat_gui/contact_list.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/chat_gui/contact_list.cpp b/src/chat_gui/contact_list.cpp index 5ab4eab3..10e8b6ea 100644 --- a/src/chat_gui/contact_list.cpp +++ b/src/chat_gui/contact_list.cpp @@ -1,6 +1,7 @@ #include "./contact_list.hpp" #include +#include #include //#include @@ -96,6 +97,11 @@ bool renderContactBig( const auto* cstate = c.try_get(); if (ImGui::BeginItemTooltip()) { + if (c.all_of()) { + const auto id_str = bin2hex(c.get().data); + ImGui::Text("ID: %s", id_str.c_str()); + } + if (cstate != nullptr) { ImGui::Text("Connection state: %s", (cstate->state == Contact::Components::ConnectionState::disconnected)