13
0

Silence detect: constrain duration in GUI.

This commit is contained in:
Robin Gareus 2015-09-19 23:33:35 +02:00
parent a6caf6ed3a
commit 21c1d0f832

View File

@ -275,13 +275,13 @@ StripSilenceDialog::threshold_changed ()
framecnt_t
StripSilenceDialog::minimum_length () const
{
return _minimum_length->current_duration (views.front().view->region()->position());
return std::max((framecnt_t)1, _minimum_length->current_duration (views.front().view->region()->position()));
}
framecnt_t
StripSilenceDialog::fade_length () const
{
return _fade_length->current_duration (views.front().view->region()->position());
return std::max((framecnt_t)0, _fade_length->current_duration (views.front().view->region()->position()));
}
void