diff --git a/src/app/MidiWidget.cpp b/src/app/MidiWidget.cpp index 739307ce..8f3216a7 100644 --- a/src/app/MidiWidget.cpp +++ b/src/app/MidiWidget.cpp @@ -1,4 +1,5 @@ #include +#include #include @@ -197,13 +198,26 @@ void MidiWidget::setMidiPort(midi::Port* port) { void appendMidiMenu(ui::Menu* menu, midi::Port* port) { - MidiDriverItem* driverItem = createMenuItem("MIDI driver", RIGHT_ARROW); - driverItem->port = port; - menu->addChild(driverItem); + menu->addChild(createMenuLabel("MIDI driver")); + appendMidiDriverMenu(menu, port); - MidiDeviceItem* deviceItem = createMenuItem("MIDI device", RIGHT_ARROW); - deviceItem->port = port; - menu->addChild(deviceItem); + menu->addChild(new ui::MenuSeparator); + menu->addChild(createMenuLabel("MIDI device")); + appendMidiDeviceMenu(menu, port); + + menu->addChild(new ui::MenuSeparator); + // menu->addChild(createMenuLabel("MIDI channel")); + // appendMidiChannelMenu(menu, port); + + // Uncomment this to use sub-menus instead of one big menu. + + // MidiDriverItem* driverItem = createMenuItem("MIDI driver", RIGHT_ARROW); + // driverItem->port = port; + // menu->addChild(driverItem); + + // MidiDeviceItem* deviceItem = createMenuItem("MIDI device", RIGHT_ARROW); + // deviceItem->port = port; + // menu->addChild(deviceItem); MidiChannelItem* channelItem = createMenuItem("MIDI channel", RIGHT_ARROW); channelItem->port = port;