Skip to content

Commit 99f68a4

Browse files
committed
fix: license dialog now responds to single click
1 parent 7402e92 commit 99f68a4

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

src/build_number.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#pragma once
2-
#define JAMWIDE_BUILD_NUMBER 106
2+
#define JAMWIDE_BUILD_NUMBER 107

src/ui/ui_main.cpp

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,10 @@ void ui_render_frame(JamWidePlugin* plugin) {
186186

187187
// === License Dialog (modal) ===
188188
if (plugin->ui_state.show_license_dialog) {
189-
ImGui::OpenPopup("Server License");
189+
// Only open popup once when dialog first appears
190+
if (!ImGui::IsPopupOpen("Server License")) {
191+
ImGui::OpenPopup("Server License");
192+
}
190193

191194
ImVec2 center = ImGui::GetMainViewport()->GetCenter();
192195
ImGui::SetNextWindowPos(center, ImGuiCond_Appearing, ImVec2(0.5f, 0.5f));
@@ -198,7 +201,10 @@ void ui_render_frame(JamWidePlugin* plugin) {
198201

199202
ImGui::Separator();
200203

201-
if (ImGui::Button("Accept", ImVec2(120, 0))) {
204+
// Make buttons larger and more clickable
205+
ImVec2 button_size(150, 30);
206+
207+
if (ImGui::Button("Accept", button_size)) {
202208
NLOG("[UI] License accepted\n");
203209
plugin->license_response.store(1, std::memory_order_release);
204210
plugin->license_cv.notify_one();
@@ -208,7 +214,7 @@ void ui_render_frame(JamWidePlugin* plugin) {
208214

209215
ImGui::SameLine();
210216

211-
if (ImGui::Button("Reject", ImVec2(120, 0))) {
217+
if (ImGui::Button("Reject", button_size)) {
212218
NLOG("[UI] License rejected\n");
213219
plugin->license_response.store(-1, std::memory_order_release);
214220
plugin->license_cv.notify_one();

0 commit comments

Comments
 (0)