@@ -502,6 +502,63 @@ void CoreActions::removeSeqBlock(int track, int index) {
502
502
ActionDispatcher::getInstance ()->dispatch (std::move (action));
503
503
}
504
504
505
+ void CoreActions::midiAddNote (
506
+ uint64_t ref, int track, double startTime, double endTime, uint8_t channel,
507
+ uint8_t pitch, uint8_t vel, const juce::String& lyrics) {
508
+ auto action = std::unique_ptr<ActionUndoableBase>(
509
+ new ActionMIDIAddNote{ ref, track, startTime, endTime,
510
+ channel, pitch, vel, lyrics });
511
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
512
+ }
513
+
514
+ void CoreActions::midiSetNoteTime (
515
+ uint64_t ref, int track, int index,
516
+ double startTime, double endTime) {
517
+ auto action = std::unique_ptr<ActionUndoableBase>(
518
+ new ActionMIDISetNoteTime{
519
+ ref, track, index , startTime, endTime });
520
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
521
+ }
522
+
523
+ void CoreActions::midiSetNoteChannel (
524
+ uint64_t ref, int track, int index,
525
+ uint8_t channel) {
526
+ auto action = std::unique_ptr<ActionUndoableBase>(
527
+ new ActionMIDISetNoteChannel{ ref, track, index , channel });
528
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
529
+ }
530
+
531
+ void CoreActions::midiSetNotePitch (
532
+ uint64_t ref, int track, int index,
533
+ uint8_t pitch) {
534
+ auto action = std::unique_ptr<ActionUndoableBase>(
535
+ new ActionMIDISetNotePitch{ ref, track, index , pitch });
536
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
537
+ }
538
+
539
+ void CoreActions::midiSetNoteVelocity (
540
+ uint64_t ref, int track, int index,
541
+ uint8_t velocity) {
542
+ auto action = std::unique_ptr<ActionUndoableBase>(
543
+ new ActionMIDISetNoteVelocity{ ref, track, index , velocity });
544
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
545
+ }
546
+
547
+ void CoreActions::midiSetNoteLyrics (
548
+ uint64_t ref, int track, int index,
549
+ const juce::String& lyrics) {
550
+ auto action = std::unique_ptr<ActionUndoableBase>(
551
+ new ActionMIDISetNoteLyrics{ ref, track, index , lyrics });
552
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
553
+ }
554
+
555
+ void CoreActions::midiRemoveNote (
556
+ uint64_t ref, int track, int index) {
557
+ auto action = std::unique_ptr<ActionUndoableBase>(
558
+ new ActionMIDIRemoveNote{ ref, track, index });
559
+ ActionDispatcher::getInstance ()->dispatch (std::move (action));
560
+ }
561
+
505
562
void CoreActions::loadProjectGUI (const juce::String& filePath) {
506
563
if (!CoreActions::askForSaveGUI ()) { return ; }
507
564
0 commit comments