From ed8b536ac02c1596923a066ecfc854a50de2846c Mon Sep 17 00:00:00 2001 From: dijunkun Date: Mon, 4 Dec 2023 14:04:36 +0800 Subject: [PATCH] Add signal connection status 'NoSuchTransmissionId' --- src/gui/main.cpp | 15 +++++++++++---- thirdparty/projectx | 2 +- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/gui/main.cpp b/src/gui/main.cpp index 076e989..904194f 100644 --- a/src/gui/main.cpp +++ b/src/gui/main.cpp @@ -560,6 +560,13 @@ void ClientConnectionStatus(ConnectionStatus status) { joined = false; connect_label = connect_button_pressed ? "Disconnect" : "Connect"; } + } else if (ConnectionStatus::NoSuchTransmissionId == status) { + client_connection_status_str = "No such transmission id"; + if (connect_button_pressed) { + connect_button_pressed = false; + joined = false; + connect_label = connect_button_pressed ? "Disconnect" : "Connect"; + } } } @@ -1031,15 +1038,15 @@ int main() { { { static char remote_id[20] = ""; - if (strcmp(remote_id, "") == 0) { - strcpy(remote_id, GetMac(mac_addr).c_str()); - } + // if (strcmp(remote_id, "") == 0) { + // strcpy(remote_id, GetMac(mac_addr).c_str()); + // } ImGui::Text("REMOTE ID:"); ImGui::SameLine(); ImGui::SetNextItemWidth(95); ImGui::InputTextWithHint("##remote_id", mac_addr, remote_id, IM_ARRAYSIZE(remote_id), - ImGuiInputTextFlags_AllowTabInput); + ImGuiInputTextFlags_CharsNoBlank); ImGui::Spacing(); diff --git a/thirdparty/projectx b/thirdparty/projectx index 25c345f..62f85bb 160000 --- a/thirdparty/projectx +++ b/thirdparty/projectx @@ -1 +1 @@ -Subproject commit 25c345f675b8a7fe9b751bd876c3840ab527fa23 +Subproject commit 62f85bb33374ad9815d532c97d3e46cb7b6cfcb8