ESFM: optimize osc buf

This commit is contained in:
tildearrow 2025-03-03 01:45:42 -05:00
parent cf4807b5d0
commit b3b50bdb66
4 changed files with 68 additions and 9 deletions

View file

@ -276,10 +276,9 @@ void FurnaceGUI::drawDebug() {
ImGui::Checkbox(fmt::sprintf("##%d_OSCFollow_%d",i,c).c_str(),&oscBuf->follow);
// address
ImGui::TableNextColumn();
int needle=oscBuf->follow?oscBuf->needle:oscBuf->followNeedle;
int needle=oscBuf->needle;
ImGui::BeginDisabled(oscBuf->follow);
if (ImGui::InputInt(fmt::sprintf("##%d_OSCFollowNeedle_%d",i,c).c_str(),&needle,1,100)) {
oscBuf->followNeedle=MIN(MAX(needle,0),65535);
}
ImGui::EndDisabled();
// data