| 402 | MidiThing* module; |
| 403 | |
| 404 | void appendContextMenu(Menu* menu) override { |
| 405 | |
| 406 | menu->addChild(new MenuSeparator()); |
| 407 | std::string label = string::f("Voltage Mode Port %d", 3 * row + col + 1); |
| 408 | |
| 409 | menu->addChild(createIndexSubmenuItem(label, |
| 410 | {"0 to 10v", "-5 to 5v", "0 to 8v", "0 to 5v"}, |
| 411 | [ = ]() { |
| 412 | return module->getVoltageMode(row, col); |
| 413 | }, |
| 414 | [ = ](int modeIdx) { |
| 415 | MidiThing::PORTMODE_t mode = (MidiThing::PORTMODE_t)(modeIdx + 1); |
| 416 | module->setVoltageModeOnHardware(row, col, mode); |
| 417 | } |
| 418 | )); |
| 419 | |
| 420 | /* |
| 421 | menu->addChild(createIndexSubmenuItem("Get Port Info", |
| 422 | {"Full", "Port", "MIDI", "Voice"}, |
| 423 | [ = ]() { |
| 424 | return -1; |
| 425 | }, |
| 426 | [ = ](int mode) { |
| 427 | module->requestParamOverSysex(row, col, 2 * mode); |
| 428 | } |
| 429 | )); |
| 430 | */ |
| 431 | } |
| 432 | }; |
| 433 | |
| 434 | // dervied from https://github.com/countmodula/VCVRackPlugins/blob/v2.0.0/src/components/CountModulaLEDDisplay.hpp |
nothing calls this directly
no test coverage detected