fixed wrong integration of tempoSyncKnobModel

git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@751 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
Tobias Doerffel
2008-03-02 07:33:18 +00:00
parent 5836c585e2
commit a6859e765a
4 changed files with 24 additions and 3 deletions

View File

@@ -96,7 +96,14 @@ ladspaControlView::ladspaControlView( QWidget * _parent,
if( knb != NULL )
{
knb->setModel( m_ctl->getKnobModel() );
if( m_ctl->getPort()->data_type != TIME )
{
knb->setModel( m_ctl->getKnobModel() );
}
else
{
knb->setModel( m_ctl->getTempoSyncKnobModel() );
}
knb->setLabel( m_ctl->getPort()->name );
knb->setHintText( tr( "Value:" ) + " ", "" );
knb->setWhatsThis( tr( "Sorry, no help available." ) );

View File

@@ -237,6 +237,10 @@ tempoSyncKnob::~tempoSyncKnob()
void tempoSyncKnob::modelChanged( void )
{
if( model() == NULL )
{
printf( "no tempoSyncKnobModel has been set!\n" );
}
m_custom->setModel( &model()->m_custom );
connect( model(), SIGNAL( syncModeChanged( tempoSyncMode ) ),
this, SLOT( updateDescAndIcon() ) );