Set default directory to the waveform directory when opening an audio file for a user-defined waveform

This commit is contained in:
Vesa
2014-01-31 17:39:44 +02:00
parent 4bcc31a80c
commit 37ad60a704
5 changed files with 22 additions and 4 deletions

View File

@@ -908,6 +908,23 @@ QString SampleBuffer::openAndSetAudioFile()
}
QString SampleBuffer::openAndSetWaveformFile()
{
if( m_audioFile.isEmpty() )
{
m_audioFile = configManager::inst()->factorySamplesDir() + "waveforms/10saw.flac";
}
QString fileName = this->openAudioFile();
if(!fileName.isEmpty())
{
this->setAudioFile( fileName );
}
return fileName;
}
#undef LMMS_HAVE_FLAC_STREAM_ENCODER_H /* not yet... */