diff --git a/src/core/automatable_model.cpp b/src/core/automatable_model.cpp index e21b2bc00..5eddd1cd8 100644 --- a/src/core/automatable_model.cpp +++ b/src/core/automatable_model.cpp @@ -1,8 +1,8 @@ /* * automatable_model.cpp - some implementations of automatableModel-class * - * Copyright (c) 2008 Tobias Doerffel - * + * Copyright (c) 2008-2009 Tobias Doerffel + * * This file is part of Linux MultiMedia Studio - http://lmms.sourceforge.net * * This program is free software; you can redistribute it and/or @@ -311,6 +311,15 @@ float automatableModel::fittedValue( float _value ) const _value = 0; } + if( _value < m_minValue ) + { + return m_minValue; + } + else if( _value > m_maxValue ) + { + return m_maxValue; + } + return _value; }