Merge pull request #1513 from DanWin/cmd
Make command line project export working again
This commit is contained in:
@@ -867,7 +867,7 @@ void AutomationPattern::generateTangents()
|
||||
void AutomationPattern::generateTangents( timeMap::const_iterator it,
|
||||
int numToGenerate )
|
||||
{
|
||||
if( m_timeMap.size() < 2 )
|
||||
if( m_timeMap.size() < 2 && numToGenerate > 0 )
|
||||
{
|
||||
m_tangents[it.key()] = 0;
|
||||
return;
|
||||
|
||||
@@ -446,14 +446,14 @@ void EnvelopeAndLfoParameters::updateSampleVars()
|
||||
{
|
||||
sample_t * tmp = m_pahdEnv;
|
||||
m_pahdEnv = new sample_t[m_pahdFrames];
|
||||
delete tmp;
|
||||
delete[] tmp;
|
||||
m_pahdBufSize = m_pahdFrames;
|
||||
}
|
||||
if( m_rBufSize < m_rFrames )
|
||||
{
|
||||
sample_t * tmp = m_rEnv;
|
||||
m_rEnv = new sample_t[m_rFrames];
|
||||
delete tmp;
|
||||
delete[] tmp;
|
||||
m_rBufSize = m_rFrames;
|
||||
}
|
||||
|
||||
|
||||
@@ -911,7 +911,10 @@ void Song::loadProject( const QString & _file_name )
|
||||
m_loadingProject = true;
|
||||
|
||||
Engine::projectJournal()->setJournalling( false );
|
||||
Engine::mainWindow()->clearErrors();
|
||||
if( Engine::mainWindow() )
|
||||
{
|
||||
Engine::mainWindow()->clearErrors();
|
||||
}
|
||||
|
||||
m_fileName = _file_name;
|
||||
m_oldFileName = _file_name;
|
||||
@@ -1023,7 +1026,10 @@ void Song::loadProject( const QString & _file_name )
|
||||
|
||||
emit projectLoaded();
|
||||
|
||||
Engine::mainWindow()->showErrors( tr( "The following errors occured while loading: " ) );
|
||||
if( Engine::mainWindow() )
|
||||
{
|
||||
Engine::mainWindow()->showErrors( tr( "The following errors occured while loading: " ) );
|
||||
}
|
||||
|
||||
m_loadingProject = false;
|
||||
m_modified = false;
|
||||
|
||||
Reference in New Issue
Block a user