zynaddsubfx

ZynAddSubFX open source synthesizer
Log | Files | Refs | Submodules | LICENSE

commit cdc70919f09ad72d211526fa87036e86245bcad3
parent 953604dcd7c46dde3cb1349b36fe6bab524aee3d
Author: Hans Petter Selasky <hps@selasky.org>
Date:   Sat,  4 Apr 2020 03:16:36 +0200

Add const keyword.
applyLegato() is not allowed to modify the LegatoParams it is passed.

Signed-off-by: Hans Petter Selasky <hps@selasky.org>

Diffstat:
Msrc/Containers/NotePool.cpp | 2+-
Msrc/Containers/NotePool.h | 2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/Containers/NotePool.cpp b/src/Containers/NotePool.cpp @@ -205,7 +205,7 @@ void NotePool::insertLegatoNote(note_t note, uint8_t sendto, SynthDescriptor des }; //There should only be one pair of notes which are still playing -void NotePool::applyLegato(note_t note, LegatoParams &par) +void NotePool::applyLegato(note_t note, const LegatoParams &par) { for(auto &desc:activeDesc()) { desc.note = note; diff --git a/src/Containers/NotePool.h b/src/Containers/NotePool.h @@ -122,7 +122,7 @@ class NotePool void insertLegatoNote(note_t note, uint8_t sendto, SynthDescriptor desc); void upgradeToLegato(void); - void applyLegato(note_t note, LegatoParams &par); + void applyLegato(note_t note, const LegatoParams &par); void makeUnsustainable(note_t note);