From 0f74039b39344181739c2aec6a2a092f9d788e46 Mon Sep 17 00:00:00 2001 From: Paul Ferrand Date: Wed, 16 Sep 2020 13:59:55 +0200 Subject: [PATCH] Make find methods const in the mod matrix --- src/sfizz/modulations/ModMatrix.cpp | 4 ++-- src/sfizz/modulations/ModMatrix.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/sfizz/modulations/ModMatrix.cpp b/src/sfizz/modulations/ModMatrix.cpp index 4533d156..d7ddc444 100644 --- a/src/sfizz/modulations/ModMatrix.cpp +++ b/src/sfizz/modulations/ModMatrix.cpp @@ -168,7 +168,7 @@ ModMatrix::TargetId ModMatrix::registerTarget(const ModKey& key) return id; } -ModMatrix::SourceId ModMatrix::findSource(const ModKey& key) +ModMatrix::SourceId ModMatrix::findSource(const ModKey& key) const { Impl& impl = *impl_; @@ -179,7 +179,7 @@ ModMatrix::SourceId ModMatrix::findSource(const ModKey& key) return SourceId(it->second); } -ModMatrix::TargetId ModMatrix::findTarget(const ModKey& key) +ModMatrix::TargetId ModMatrix::findTarget(const ModKey& key) const { Impl& impl = *impl_; diff --git a/src/sfizz/modulations/ModMatrix.h b/src/sfizz/modulations/ModMatrix.h index b0f9f58f..0f0fb471 100644 --- a/src/sfizz/modulations/ModMatrix.h +++ b/src/sfizz/modulations/ModMatrix.h @@ -77,14 +77,14 @@ public: * * @param key source key */ - SourceId findSource(const ModKey& key); + SourceId findSource(const ModKey& key) const; /** * @brief Look up a target by key. * * @param key target key */ - TargetId findTarget(const ModKey& key); + TargetId findTarget(const ModKey& key) const; /** * @brief Connect a source and a destination inside the matrix.