TimeMicros::fromString()

and improve the cue position editor a bit
This commit is contained in:
tildearrow 2025-10-31 03:42:43 -05:00
parent 3516245d2e
commit e8aeb45a12
6 changed files with 259 additions and 14 deletions

View file

@ -25,6 +25,7 @@
#include <fmt/printf.h>
#include "imgui.h"
#include "imgui_internal.h"
#include "misc/cpp/imgui_stdlib.h"
PendingDrawOsc _debugDo;
static float oscDebugData[2048];
@ -369,6 +370,25 @@ void FurnaceGUI::drawDebug() {
ImGui::Unindent();
ImGui::TreePop();
}
if (ImGui::TreeNode("TimeMicros Test")) {
static TimeMicros testTS;
static String testTSIn;
String testTSFormatted=testTS.toString();
ImGui::Text("Current Value: %s",testTSFormatted.c_str());
if (ImGui::InputText("fromString",&testTSIn)) {
try {
testTS=TimeMicros::fromString(testTSIn);
} catch (std::invalid_argument& e) {
ImGui::Text("COULD NOT! (%s)",e.what());
}
}
ImGui::InputInt("seconds",&testTS.seconds);
ImGui::InputInt("micros",&testTS.micros);
ImGui::TreePop();
}
if (ImGui::TreeNode("New File Picker Test")) {
static bool check0, check1, check2, check3, check4, check5;