Piano Roll Session
A live editing session over one MIDI clip. Owned by the model — obtain one with AppModel.openPianoRollSession and release it with AppModel.closePianoRollSession.
Inheritors
Properties
The document reference id of the clip being edited, or null.
The note the detail editor is on, or -1.
The selection context this session publishes its note selection in; hand it to ProjectSelectionService.snapshot and friends. null when the session has none.
Functions
A move drag works from the notes as they were when it began, so each update re-applies one delta rather than accumulating rounding. The session holds that snapshot: say when the drag starts, how far it has moved, and whether it ended or was cancelled.
Whether this session was built from that snapshot's UMP stream. False means the clip changed underneath and the session must be reloaded — which is what stops an edit being applied to a clip it was not made against.
The document reference id of the note at index, or null for an unknown index.
index -1 clears the selection.
Re-reads the session's selection from the selection service, for when it changed elsewhere.