From 1c31bb5c84b7a90171f557f2e75f481e5878e8ab Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Mon, 25 Sep 2017 18:19:13 +0300 Subject: [PATCH 01/14] Initial commit. --- CMakeLists.txt | 2 +- src/gui/AboutDialog.cpp | 34 +++---- src/gui/ExportProjectDialog.cpp | 146 ++++++++++++++++-------------- src/gui/dialogs/about_dialog.ui | 32 +++---- src/gui/dialogs/export_project.ui | 76 ++++++++-------- 5 files changed, 150 insertions(+), 140 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8c8c48eeb4f..22291d6567d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,7 +22,7 @@ STRING(TOUPPER "${CMAKE_PROJECT_NAME}" PROJECT_NAME_UCASE) # Updated by maintenance tasks SET(PROJECT_YEAR 2015) -SET(PROJECT_AUTHOR "LMMS Developers") +SET(PROJECT_AUTHOR "LMMS developers") SET(PROJECT_URL "https://lmms.io") SET(PROJECT_EMAIL "lmms-devel@lists.sourceforge.net") SET(PROJECT_DESCRIPTION "${PROJECT_NAME_UCASE} - Free music production software") diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp index 618d35966a8..35261818522 100644 --- a/src/gui/AboutDialog.cpp +++ b/src/gui/AboutDialog.cpp @@ -29,32 +29,34 @@ #include "versioninfo.h" - AboutDialog::AboutDialog(QWidget* parent) : QDialog(parent), Ui::AboutDialog() { - setupUi( this ); + setupUi(this); - iconLabel->setPixmap( embed::getIconPixmap( "icon", 64, 64 ) ); + iconLabel->setPixmap(embed::getIconPixmap("icon", 64, 64)); - versionLabel->setText( versionLabel->text(). - arg( LMMS_VERSION ). - arg( PLATFORM ). - arg( MACHINE ). - arg( QT_VERSION_STR ). - arg( GCC_VERSION ) ); + versionLabel->setText(versionLabel->text(). + arg(LMMS_VERSION). + arg(PLATFORM). + arg(MACHINE). + arg(QT_VERSION_STR). + arg(GCC_VERSION)); versionLabel->setTextInteractionFlags( - versionLabel->textInteractionFlags() | - Qt::TextSelectableByMouse ); + versionLabel->textInteractionFlags() | + Qt::TextSelectableByMouse); - copyrightLabel->setText( copyrightLabel->text(). - arg( LMMS_PROJECT_COPYRIGHT ) ); + copyrightLabel->setText(copyrightLabel->text(). + arg(LMMS_PROJECT_COPYRIGHT)); - authorLabel->setPlainText( embed::getText( "AUTHORS" ) ); + authorLabel->setPlainText( + embed::getText("AUTHORS")); - licenseLabel->setPlainText( embed::getText( "LICENSE.txt" ) ); + licenseLabel->setPlainText( + embed::getText("LICENSE.txt")); - involvedLabel->setPlainText( embed::getText( "CONTRIBUTORS" ) ); + involvedLabel->setPlainText( + embed::getText("CONTRIBUTORS")); } diff --git a/src/gui/ExportProjectDialog.cpp b/src/gui/ExportProjectDialog.cpp index d17981c9ec8..a594973afb1 100644 --- a/src/gui/ExportProjectDialog.cpp +++ b/src/gui/ExportProjectDialog.cpp @@ -22,6 +22,7 @@ * */ + #include #include #include @@ -34,48 +35,47 @@ #include "OutputSettings.h" -ExportProjectDialog::ExportProjectDialog( const QString & _file_name, - QWidget * _parent, bool multi_export=false ) : - QDialog( _parent ), +ExportProjectDialog::ExportProjectDialog(const QString & _file_name, + QWidget * _parent, bool multi_export=false) : + QDialog(_parent), Ui::ExportProjectDialog(), - m_fileName( _file_name ), + m_fileName(_file_name), m_fileExtension(), - m_multiExport( multi_export ), - m_renderManager( nullptr ) + m_multiExport(multi_export), + m_renderManager(nullptr) { - setupUi( this ); - setWindowTitle( tr( "Export project to %1" ).arg( - QFileInfo( _file_name ).fileName() ) ); + setupUi(this); + setWindowTitle(tr("Export project to %1").arg( + QFileInfo(_file_name).fileName())); - // get the extension of the chosen file - QStringList parts = _file_name.split( '.' ); + // Get the extension of the chosen file. + QStringList parts = _file_name.split('.'); QString fileExt; - if( parts.size() > 0 ) + if(parts.size() > 0) { fileExt = "." + parts[parts.size()-1]; } int cbIndex = 0; - for( int i = 0; i < ProjectRenderer::NumFileFormats; ++i ) + for(int i = 0; i < ProjectRenderer::NumFileFormats; ++i) { - if( ProjectRenderer::fileEncodeDevices[i].isAvailable() ) + if(ProjectRenderer::fileEncodeDevices[i].isAvailable()) { - // get the extension of this format + // Get the extension of this format. QString renderExt = ProjectRenderer::fileEncodeDevices[i].m_extension; - // add to combo box - fileFormatCB->addItem( ProjectRenderer::tr( - ProjectRenderer::fileEncodeDevices[i].m_description ), - QVariant(ProjectRenderer::fileEncodeDevices[i].m_fileFormat) // format tag; later used for identification + // Add to combo box. + fileFormatCB->addItem(ProjectRenderer::tr( + ProjectRenderer::fileEncodeDevices[i].m_description), + QVariant(ProjectRenderer::fileEncodeDevices[i].m_fileFormat) // Format tag; later used for identification. ); - // if this is our extension, select it - if( QString::compare( renderExt, fileExt, - Qt::CaseInsensitive ) == 0 ) + // If this is our extension, select it. + if(QString::compare(renderExt, fileExt, + Qt::CaseInsensitive) == 0) { - fileFormatCB->setCurrentIndex( cbIndex ); + fileFormatCB->setCurrentIndex(cbIndex); } - cbIndex++; } } @@ -84,9 +84,8 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, for(int i=0; i<=MAX_LEVEL; ++i) { QString info=""; - if (i==0){ info = tr("(fastest)"); } - else if (i==4){ info = tr("(default)"); } - else if (i==MAX_LEVEL){ info = tr("(smallest)"); } + if (i==0){ info = tr("(Fastest - biggest)"); } + else if (i==MAX_LEVEL){ info = tr("(Slowest - smallest)"); } compLevelCB->addItem( QString::number(i)+" "+info, @@ -95,18 +94,20 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, } compLevelCB->setCurrentIndex(MAX_LEVEL/2); #ifndef LMMS_HAVE_SF_COMPLEVEL - //Disable this widget; the setting would be ignored by the renderer. + // Disable this widget; the setting would be ignored by the renderer. compressionWidget->setVisible(false); #endif - connect( startButton, SIGNAL( clicked() ), - this, SLOT( startBtnClicked() ) ); + connect(startButton, SIGNAL(clicked()), + this, SLOT(startBtnClicked())); } + + void ExportProjectDialog::reject() { - if( m_renderManager ) { + if(m_renderManager) { m_renderManager->abortProcessing(); } m_renderManager.reset(nullptr); @@ -116,6 +117,7 @@ void ExportProjectDialog::reject() + void ExportProjectDialog::accept() { m_renderManager.reset(nullptr); @@ -125,16 +127,18 @@ void ExportProjectDialog::accept() -void ExportProjectDialog::closeEvent( QCloseEvent * _ce ) +void ExportProjectDialog::closeEvent(QCloseEvent * _ce) { - if( m_renderManager ) { + if(m_renderManager) + { m_renderManager->abortProcessing(); } - - QDialog::closeEvent( _ce ); + QDialog::closeEvent(_ce); } + + OutputSettings::StereoMode mapToStereoMode(int index) { switch (index) @@ -150,12 +154,15 @@ OutputSettings::StereoMode mapToStereoMode(int index) } } + + + void ExportProjectDialog::startExport() { Mixer::qualitySettings qs = Mixer::qualitySettings( - static_cast(interpolationCB->currentIndex()), - static_cast(oversamplingCB->currentIndex()) ); + static_cast(interpolationCB->currentIndex()), + static_cast(oversamplingCB->currentIndex())); const int samplerates[5] = { 44100, 48000, 88200, 96000, 192000 }; const bitrate_t bitrates[6] = { 64, 128, 160, 192, 256, 320 }; @@ -166,8 +173,8 @@ void ExportProjectDialog::startExport() OutputSettings os = OutputSettings( samplerates[ samplerateCB->currentIndex() ], bitRateSettings, - static_cast( depthCB->currentIndex() ), - mapToStereoMode(stereoModeComboBox->currentIndex()) ); + static_cast(depthCB->currentIndex()), + mapToStereoMode(stereoModeComboBox->currentIndex())); if (compressionWidget->isVisible()) { @@ -175,28 +182,28 @@ void ExportProjectDialog::startExport() os.setCompressionLevel(level); } - //Make sure we have the the correct file extension - //so there's no confusion about the codec in use. + // Make sure we have the the correct file extension + // so there's no confusion about the codec in use. auto output_name = m_fileName; if (!(m_multiExport || output_name.endsWith(m_fileExtension,Qt::CaseInsensitive))) { output_name+=m_fileExtension; } - m_renderManager.reset(new RenderManager( qs, os, m_ft, output_name )); + m_renderManager.reset(new RenderManager(qs, os, m_ft, output_name)); - Engine::getSong()->setExportLoop( exportLoopCB->isChecked() ); - Engine::getSong()->setRenderBetweenMarkers( renderMarkersCB->isChecked() ); + Engine::getSong()->setExportLoop(exportLoopCB->isChecked()); + Engine::getSong()->setRenderBetweenMarkers(renderMarkersCB->isChecked()); - connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), - progressBar, SLOT( setValue( int ) ) ); - connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), - this, SLOT( updateTitleBar( int ) )) ; - connect( m_renderManager.get(), SIGNAL( finished() ), - this, SLOT( accept() ) ); - connect( m_renderManager.get(), SIGNAL( finished() ), - gui->mainWindow(), SLOT( resetWindowTitle() ) ); + connect(m_renderManager.get(), SIGNAL(progressChanged(int)), + progressBar, SLOT(setValue(int))); + connect(m_renderManager.get(), SIGNAL(progressChanged(int)), + this, SLOT(updateTitleBar(int))) ; + connect(m_renderManager.get(), SIGNAL(finished()), + this, SLOT(accept())); + connect(m_renderManager.get(), SIGNAL(finished()), + gui->mainWindow(), SLOT(resetWindowTitle())); - if ( m_multiExport ) + if (m_multiExport) { m_renderManager->renderTracks(); } @@ -207,6 +214,8 @@ void ExportProjectDialog::startExport() } + + void ExportProjectDialog::onFileFormatChanged(int index) { // Extract the format tag from the currently selected item, @@ -246,41 +255,42 @@ void ExportProjectDialog::onFileFormatChanged(int index) depthWidget->setVisible(bitDepthControlEnabled); } + + + void ExportProjectDialog::startBtnClicked() { m_ft = ProjectRenderer::NumFileFormats; - //Get file format from current menu selection. + // Get file format from current menu selection. bool successful_conversion = false; QVariant tag = fileFormatCB->itemData(fileFormatCB->currentIndex()); m_ft = static_cast( - tag.toInt(&successful_conversion) - ); + tag.toInt(&successful_conversion)); - if( !successful_conversion ) + if(!successful_conversion) { - QMessageBox::information( this, tr( "Error" ), - tr( "Error while determining file-encoder device. " + QMessageBox::information(this, tr("Error"), + tr("Error while determining file-encoder device. " "Please try to choose a different output " - "format." ) ); + "format.")); reject(); return; } // Find proper file extension. - for( int i = 0; i < ProjectRenderer::NumFileFormats; ++i ) + for(int i = 0; i < ProjectRenderer::NumFileFormats; ++i) { if (m_ft == ProjectRenderer::fileEncodeDevices[i].m_fileFormat) { - m_fileExtension = QString( QLatin1String( ProjectRenderer::fileEncodeDevices[i].m_extension ) ); + m_fileExtension = QString(QLatin1String(ProjectRenderer::fileEncodeDevices[i].m_extension)); break; } } + startButton->setEnabled(false); + progressBar->setEnabled(true); - startButton->setEnabled( false ); - progressBar->setEnabled( true ); - - updateTitleBar( 0 ); + updateTitleBar(0); startExport(); } @@ -288,8 +298,8 @@ void ExportProjectDialog::startBtnClicked() -void ExportProjectDialog::updateTitleBar( int _prog ) +void ExportProjectDialog::updateTitleBar(int _prog) { gui->mainWindow()->setWindowTitle( - tr( "Rendering: %1%" ).arg( _prog ) ); + tr("Rendering: %1%").arg(_prog)); } diff --git a/src/gui/dialogs/about_dialog.ui b/src/gui/dialogs/about_dialog.ui index fbc1b56cdb5..2a654c87264 100644 --- a/src/gui/dialogs/about_dialog.ui +++ b/src/gui/dialogs/about_dialog.ui @@ -7,13 +7,13 @@ 0 0 558 - 357 + 358 558 - 357 + 358 @@ -46,7 +46,6 @@ - @@ -65,7 +64,7 @@ - Version %1 (%2/%3, Qt %4, %5) + Version %1 (%2/%3, Qt %4, %5). @@ -78,8 +77,8 @@ - 40 - 20 + 0 + 0 @@ -106,8 +105,8 @@ - 20 - 10 + 0 + 0 @@ -115,7 +114,7 @@ - LMMS - easy music production for everyone + LMMS - easy music production for everyone. true @@ -132,8 +131,8 @@ - 20 - 10 + 0 + 0 @@ -141,7 +140,7 @@ - Copyright © %1 + Copyright © %1. true @@ -158,8 +157,8 @@ - 20 - 10 + 0 + 0 @@ -181,8 +180,8 @@ - 20 - 40 + 0 + 0 @@ -236,7 +235,6 @@ Current language not translated (or native English). - If you're interested in translating LMMS in another language or want to improve existing translations, you're welcome to help us! Simply contact the maintainer! diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index 43ad56f3541..8c40379bdab 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -6,26 +6,40 @@ 0 0 - 715 - 491 + 374 + 374 - 519 - 412 + 374 + 374 Export project + + + + Export as loop (remove end silence) + + + + + + + Export between loop markers + + + - Output + File format settings @@ -62,7 +76,7 @@ - Samplerate: + Sampling rate: @@ -122,7 +136,7 @@ - Depth: + Bit depth: @@ -133,17 +147,17 @@ - 16 Bit Integer + 16 Bit integer - 24 Bit Integer + 24 Bit integer - 32 Bit Float + 32 Bit float @@ -180,17 +194,17 @@ - Stereo + Mono - Joint Stereo + Stereo - Mono + Joint stereo @@ -312,8 +326,8 @@ - 163 - 20 + 0 + 0 @@ -341,22 +355,22 @@ - Zero Order Hold + Zero order hold - Sinc Fastest + Sinc worst (fastest) - Sinc Medium (recommended) + Sinc medium (recommended) - Sinc Best (very slow!) + Sinc best (slowest) @@ -364,7 +378,7 @@ - Oversampling (use with care!): + Oversampling: @@ -392,20 +406,6 @@ - - - - Export as loop (remove end silence) - - - - - - - Export between loop markers - - - @@ -413,8 +413,8 @@ - 20 - 40 + 0 + 0 @@ -433,8 +433,8 @@ - 40 - 20 + 0 + 0 From d1e2815fa801529f63626867cd81f7e01f57975c Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Mon, 25 Sep 2017 18:42:12 +0300 Subject: [PATCH 02/14] Fixes. --- src/core/ProjectRenderer.cpp | 162 ++++++++++++++++---------------- src/gui/ExportProjectDialog.cpp | 2 +- 2 files changed, 80 insertions(+), 84 deletions(-) diff --git a/src/core/ProjectRenderer.cpp b/src/core/ProjectRenderer.cpp index 52c4a16a417..6efc3cb12f0 100644 --- a/src/core/ProjectRenderer.cpp +++ b/src/core/ProjectRenderer.cpp @@ -37,55 +37,54 @@ #include "sched.h" #endif + const ProjectRenderer::FileEncodeDevice ProjectRenderer::fileEncodeDevices[] = { - - { ProjectRenderer::WaveFile, - QT_TRANSLATE_NOOP( "ProjectRenderer", "WAV-File (*.wav)" ), - ".wav", &AudioFileWave::getInst }, - { ProjectRenderer::FlacFile, - QT_TRANSLATE_NOOP("ProjectRenderer", "FLAC-File (*.flac)"), - ".flac", - &AudioFileFlac::getInst + {ProjectRenderer::WaveFile, + QT_TRANSLATE_NOOP("ProjectRenderer", "WAV (*.wav)"), + ".wav", &AudioFileWave::getInst}, + {ProjectRenderer::FlacFile, + QT_TRANSLATE_NOOP("ProjectRenderer", "FLAC (*.flac)"), + ".flac", + &AudioFileFlac::getInst }, - { ProjectRenderer::OggFile, - QT_TRANSLATE_NOOP( "ProjectRenderer", "Compressed OGG-File (*.ogg)" ), - ".ogg", + {ProjectRenderer::OggFile, + QT_TRANSLATE_NOOP("ProjectRenderer", "OGG (*.ogg)"), + ".ogg", #ifdef LMMS_HAVE_OGGVORBIS - &AudioFileOgg::getInst + &AudioFileOgg::getInst #else - NULL + NULL #endif - }, - { ProjectRenderer::MP3File, - QT_TRANSLATE_NOOP( "ProjectRenderer", "Compressed MP3-File (*.mp3)" ), - ".mp3", + }, + {ProjectRenderer::MP3File, + QT_TRANSLATE_NOOP("ProjectRenderer", "MP3 (*.mp3)"), + ".mp3", #ifdef LMMS_HAVE_MP3LAME - &AudioFileMP3::getInst + &AudioFileMP3::getInst #else - NULL + NULL #endif - }, - // ... insert your own file-encoder-infos here... may be one day the - // user can add own encoders inside the program... - - { ProjectRenderer::NumFileFormats, NULL, NULL, NULL } + }, + // Insert your own file-encoder infos here. + // Maybe one day the user can add own encoders inside the program. -} ; + {ProjectRenderer::NumFileFormats, NULL, NULL, NULL} +}; -ProjectRenderer::ProjectRenderer( const Mixer::qualitySettings & qualitySettings, - const OutputSettings & outputSettings, - ExportFileFormats exportFileFormat, - const QString & outputFilename ) : - QThread( Engine::mixer() ), - m_fileDev( NULL ), - m_qualitySettings( qualitySettings ), - m_oldQualitySettings( Engine::mixer()->currentQualitySettings() ), - m_progress( 0 ), - m_abort( false ) +ProjectRenderer::ProjectRenderer(const Mixer::qualitySettings & qualitySettings, + const OutputSettings & outputSettings, + ExportFileFormats exportFileFormat, + const QString & outputFilename) : + QThread(Engine::mixer()), + m_fileDev(NULL), + m_qualitySettings(qualitySettings), + m_oldQualitySettings(Engine::mixer()->currentQualitySettings()), + m_progress(0), + m_abort(false) { AudioFileDeviceInstantiaton audioEncoderFactory = fileEncodeDevices[exportFileFormat].m_getDevInst; @@ -95,8 +94,8 @@ ProjectRenderer::ProjectRenderer( const Mixer::qualitySettings & qualitySettings m_fileDev = audioEncoderFactory( outputFilename, outputSettings, DEFAULT_CHANNELS, - Engine::mixer(), successful ); - if( !successful ) + Engine::mixer(), successful); + if(!successful) { delete m_fileDev; m_fileDev = NULL; @@ -109,36 +108,35 @@ ProjectRenderer::ProjectRenderer( const Mixer::qualitySettings & qualitySettings ProjectRenderer::~ProjectRenderer() { - Engine::mixer()->restoreAudioDevice(); // also deletes audio-dev - Engine::mixer()->changeQuality( m_oldQualitySettings ); + Engine::mixer()->restoreAudioDevice(); // Also deletes audio dev. + Engine::mixer()->changeQuality(m_oldQualitySettings); } -// little help-function for getting file-format from a file-extension (only for -// registered file-encoders) +// Little help function for getting file format from a file extension +// (only for registered file-encoders). ProjectRenderer::ExportFileFormats ProjectRenderer::getFileFormatFromExtension( - const QString & _ext ) + const QString & _ext) { int idx = 0; - while( fileEncodeDevices[idx].m_fileFormat != NumFileFormats ) + while(fileEncodeDevices[idx].m_fileFormat != NumFileFormats) { - if( QString( fileEncodeDevices[idx].m_extension ) == _ext ) + if(QString(fileEncodeDevices[idx].m_extension) == _ext) { - return( fileEncodeDevices[idx].m_fileFormat ); + return(fileEncodeDevices[idx].m_fileFormat); } ++idx; } - - return( WaveFile ); // default + return(WaveFile); // Default. } QString ProjectRenderer::getFileExtensionFromFormat( - ExportFileFormats fmt ) + ExportFileFormats fmt) { return fileEncodeDevices[fmt].m_extension; } @@ -149,74 +147,74 @@ QString ProjectRenderer::getFileExtensionFromFormat( void ProjectRenderer::startProcessing() { - if( isReady() ) + if(isReady()) { - // have to do mixer stuff with GUI-thread-affinity in order to - // make slots connected to sampleRateChanged()-signals being - // called immediately - Engine::mixer()->setAudioDevice( m_fileDev, - m_qualitySettings, false ); + // Have to do mixer stuff with GUI-thread affinity in order to + // make slots connected to sampleRateChanged()-signals being called immediately. + Engine::mixer()->setAudioDevice(m_fileDev, + m_qualitySettings, false); start( #ifndef LMMS_BUILD_WIN32 - QThread::HighPriority + QThread::HighPriority #endif - ); - +); } } + + void ProjectRenderer::run() { #if 0 #ifdef LMMS_BUILD_LINUX #ifdef LMMS_HAVE_SCHED_H cpu_set_t mask; - CPU_ZERO( &mask ); - CPU_SET( 0, &mask ); - sched_setaffinity( 0, sizeof( mask ), &mask ); + CPU_ZERO(&mask); + CPU_SET(0, &mask); + sched_setaffinity(0, sizeof(mask), &mask); #endif #endif #endif Engine::getSong()->startExport(); Engine::getSong()->updateLength(); - //skip first empty buffer + // Skip first empty buffer. Engine::mixer()->nextBuffer(); const Song::PlayPos & exportPos = Engine::getSong()->getPlayPos( - Song::Mode_PlaySong ); + Song::Mode_PlaySong); m_progress = 0; std::pair exportEndpoints = Engine::getSong()->getExportEndpoints(); tick_t startTick = exportEndpoints.first.getTicks(); tick_t endTick = exportEndpoints.second.getTicks(); tick_t lengthTicks = endTick - startTick; - // Continually track and emit progress percentage to listeners - while( exportPos.getTicks() < endTick && - Engine::getSong()->isExporting() == true - && !m_abort ) + // Continually track and emit progress percentage to listeners. + while(exportPos.getTicks() < endTick && + Engine::getSong()->isExporting() == true + && !m_abort) { m_fileDev->processNextBuffer(); const int nprog = lengthTicks == 0 ? 100 : (exportPos.getTicks()-startTick) * 100 / lengthTicks; - if( m_progress != nprog ) + if(m_progress != nprog) { m_progress = nprog; - emit progressChanged( m_progress ); + emit progressChanged(m_progress); } } - // notify mixer of the end of processing + // Notify mixer of the end of processing. Engine::mixer()->stopProcessing(); Engine::getSong()->stopExport(); - // if the user aborted export-process, the file has to be deleted + // If the user aborted export-process, the file has to be deleted. const QString f = m_fileDev->outputFile(); - if( m_abort ) + if(m_abort) { - QFile( f ).remove(); + QFile(f).remove(); } } @@ -231,6 +229,7 @@ void ProjectRenderer::abortProcessing() + void ProjectRenderer::updateConsoleProgress() { const int cols = 50; @@ -238,21 +237,18 @@ void ProjectRenderer::updateConsoleProgress() char buf[80]; char prog[cols+1]; - for( int i = 0; i < cols; ++i ) + for(int i = 0; i < cols; ++i) { - prog[i] = ( i*100/cols <= m_progress ? '-' : ' ' ); + prog[i] = (i*100/cols <= m_progress ? '-' : ' '); } prog[cols] = 0; const char * activity = (const char *) "|/-\\"; - memset( buf, 0, sizeof( buf ) ); - sprintf( buf, "\r|%s| %3d%% %c ", prog, m_progress, - activity[rot] ); - rot = ( rot+1 ) % 4; + memset(buf, 0, sizeof(buf)); + sprintf(buf, "\r|%s| %3d%% %c ", prog, m_progress, + activity[rot]); + rot = (rot+1) % 4; - fprintf( stderr, "%s", buf ); - fflush( stderr ); + fprintf(stderr, "%s", buf); + fflush(stderr); } - - - diff --git a/src/gui/ExportProjectDialog.cpp b/src/gui/ExportProjectDialog.cpp index a594973afb1..efa1ff3e802 100644 --- a/src/gui/ExportProjectDialog.cpp +++ b/src/gui/ExportProjectDialog.cpp @@ -197,7 +197,7 @@ void ExportProjectDialog::startExport() connect(m_renderManager.get(), SIGNAL(progressChanged(int)), progressBar, SLOT(setValue(int))); connect(m_renderManager.get(), SIGNAL(progressChanged(int)), - this, SLOT(updateTitleBar(int))) ; + this, SLOT(updateTitleBar(int))); connect(m_renderManager.get(), SIGNAL(finished()), this, SLOT(accept())); connect(m_renderManager.get(), SIGNAL(finished()), From b1cc94233ea6837c7276c958ddc6c9162eddb179 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Tue, 26 Sep 2017 15:10:42 +0300 Subject: [PATCH 03/14] Some about dialog changes. --- src/gui/AboutDialog.cpp | 6 +++--- src/gui/dialogs/about_dialog.ui | 10 ++++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp index 35261818522..477f7cb2a50 100644 --- a/src/gui/AboutDialog.cpp +++ b/src/gui/AboutDialog.cpp @@ -54,9 +54,9 @@ AboutDialog::AboutDialog(QWidget* parent) : authorLabel->setPlainText( embed::getText("AUTHORS")); + /*involvedLabel->setPlainText( + embed::getText("CONTRIBUTORS"));*/ + licenseLabel->setPlainText( embed::getText("LICENSE.txt")); - - involvedLabel->setPlainText( - embed::getText("CONTRIBUTORS")); } diff --git a/src/gui/dialogs/about_dialog.ui b/src/gui/dialogs/about_dialog.ui index 2a654c87264..b03561affb9 100644 --- a/src/gui/dialogs/about_dialog.ui +++ b/src/gui/dialogs/about_dialog.ui @@ -6,14 +6,14 @@ 0 0 - 558 - 358 + 500 + 270 - 558 - 358 + 500 + 270 @@ -202,6 +202,7 @@ + Translation From b2ea361e655544d37f6a540d2f86e3a1362e75d4 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Tue, 26 Sep 2017 17:29:42 +0300 Subject: [PATCH 04/14] Change color of link to something green-ish. --- src/gui/dialogs/about_dialog.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/dialogs/about_dialog.ui b/src/gui/dialogs/about_dialog.ui index b03561affb9..0dfa7293073 100644 --- a/src/gui/dialogs/about_dialog.ui +++ b/src/gui/dialogs/about_dialog.ui @@ -166,7 +166,7 @@ - <html><head/><body><p><a href="https://lmms.io"><span style=" text-decoration: underline; color:#0000ff;">https://lmms.io</span></a></p></body></html> + <html><head/><body><p><a href="https://lmms.io"><span style=" text-decoration: underline; color:#33cc33;">https://lmms.io</span></a></p></body></html> true From 04046395f95181a92c5cf8fc8b62c2e28a9684bd Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Tue, 26 Sep 2017 19:55:13 +0300 Subject: [PATCH 05/14] Commeneted out useless code. --- src/gui/dialogs/about_dialog.ui | 14 ++++++++++---- src/gui/dialogs/export_project.ui | 8 ++++++++ 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/src/gui/dialogs/about_dialog.ui b/src/gui/dialogs/about_dialog.ui index 0dfa7293073..6930b402e67 100644 --- a/src/gui/dialogs/about_dialog.ui +++ b/src/gui/dialogs/about_dialog.ui @@ -6,20 +6,21 @@ 0 0 - 500 - 270 + 504 + 286 - 500 - 270 + 504 + 286 About LMMS + @@ -278,6 +280,7 @@ If you're interested in translating LMMS in another language or want to improve accepted() AboutDialog accept() + buttonBox rejected() AboutDialog reject() + diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index 8c40379bdab..7985baab666 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -42,12 +42,14 @@ File format settings + @@ -114,12 +116,14 @@ + 0 @@ -239,9 +243,11 @@ -1 + @@ -250,9 +256,11 @@ + 0 From 1da95bafc084fc8a7aab16fe97271f02cb3ecf7c Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Wed, 27 Sep 2017 15:33:30 +0300 Subject: [PATCH 06/14] Formatting reverse. --- src/core/ProjectRenderer.cpp | 139 +++++++++++----------- src/gui/AboutDialog.cpp | 33 +++--- src/gui/ExportProjectDialog.cpp | 196 +++++++++++++++----------------- 3 files changed, 180 insertions(+), 188 deletions(-) diff --git a/src/core/ProjectRenderer.cpp b/src/core/ProjectRenderer.cpp index 6efc3cb12f0..0b19f72b273 100644 --- a/src/core/ProjectRenderer.cpp +++ b/src/core/ProjectRenderer.cpp @@ -37,65 +37,66 @@ #include "sched.h" #endif - const ProjectRenderer::FileEncodeDevice ProjectRenderer::fileEncodeDevices[] = { - {ProjectRenderer::WaveFile, - QT_TRANSLATE_NOOP("ProjectRenderer", "WAV (*.wav)"), - ".wav", &AudioFileWave::getInst}, - {ProjectRenderer::FlacFile, - QT_TRANSLATE_NOOP("ProjectRenderer", "FLAC (*.flac)"), - ".flac", - &AudioFileFlac::getInst + + { ProjectRenderer::WaveFile, + QT_TRANSLATE_NOOP( "ProjectRenderer", "WAV (*.wav)" ), + ".wav", &AudioFileWave::getInst }, + { ProjectRenderer::FlacFile, + QT_TRANSLATE_NOOP( "ProjectRenderer", "FLAC (*.flac)" ), + ".flac", + &AudioFileFlac::getInst }, - {ProjectRenderer::OggFile, - QT_TRANSLATE_NOOP("ProjectRenderer", "OGG (*.ogg)"), - ".ogg", + { ProjectRenderer::OggFile, + QT_TRANSLATE_NOOP( "ProjectRenderer", "OGG (*.ogg)" ), + ".ogg", #ifdef LMMS_HAVE_OGGVORBIS - &AudioFileOgg::getInst + &AudioFileOgg::getInst #else - NULL + NULL #endif }, - {ProjectRenderer::MP3File, - QT_TRANSLATE_NOOP("ProjectRenderer", "MP3 (*.mp3)"), - ".mp3", + { ProjectRenderer::MP3File, + QT_TRANSLATE_NOOP( "ProjectRenderer", "MP3 (*.mp3)" ), + ".mp3", #ifdef LMMS_HAVE_MP3LAME - &AudioFileMP3::getInst + &AudioFileMP3::getInst #else - NULL + NULL #endif }, // Insert your own file-encoder infos here. // Maybe one day the user can add own encoders inside the program. - {ProjectRenderer::NumFileFormats, NULL, NULL, NULL} -}; + { ProjectRenderer::NumFileFormats, NULL, NULL, NULL } + +} ; -ProjectRenderer::ProjectRenderer(const Mixer::qualitySettings & qualitySettings, - const OutputSettings & outputSettings, - ExportFileFormats exportFileFormat, - const QString & outputFilename) : - QThread(Engine::mixer()), - m_fileDev(NULL), - m_qualitySettings(qualitySettings), - m_oldQualitySettings(Engine::mixer()->currentQualitySettings()), - m_progress(0), - m_abort(false) +ProjectRenderer::ProjectRenderer( const Mixer::qualitySettings & qualitySettings, + const OutputSettings & outputSettings, + ExportFileFormats exportFileFormat, + const QString & outputFilename ) : + QThread( Engine::mixer() ), + m_fileDev( NULL ), + m_qualitySettings( qualitySettings ), + m_oldQualitySettings( Engine::mixer()->currentQualitySettings() ), + m_progress( 0 ), + m_abort( false ) { AudioFileDeviceInstantiaton audioEncoderFactory = fileEncodeDevices[exportFileFormat].m_getDevInst; - if (audioEncoderFactory) + if ( audioEncoderFactory ) { bool successful = false; m_fileDev = audioEncoderFactory( outputFilename, outputSettings, DEFAULT_CHANNELS, - Engine::mixer(), successful); - if(!successful) + Engine::mixer(), successful ); + if( !successful ) { delete m_fileDev; m_fileDev = NULL; @@ -109,7 +110,7 @@ ProjectRenderer::ProjectRenderer(const Mixer::qualitySettings & qualitySettings, ProjectRenderer::~ProjectRenderer() { Engine::mixer()->restoreAudioDevice(); // Also deletes audio dev. - Engine::mixer()->changeQuality(m_oldQualitySettings); + Engine::mixer()->changeQuality( m_oldQualitySettings ); } @@ -118,25 +119,26 @@ ProjectRenderer::~ProjectRenderer() // Little help function for getting file format from a file extension // (only for registered file-encoders). ProjectRenderer::ExportFileFormats ProjectRenderer::getFileFormatFromExtension( - const QString & _ext) + const QString & _ext ) { int idx = 0; - while(fileEncodeDevices[idx].m_fileFormat != NumFileFormats) + while( fileEncodeDevices[idx].m_fileFormat != NumFileFormats ) { - if(QString(fileEncodeDevices[idx].m_extension) == _ext) + if( QString( fileEncodeDevices[idx].m_extension ) == _ext ) { - return(fileEncodeDevices[idx].m_fileFormat); + return( fileEncodeDevices[idx].m_fileFormat ); } ++idx; } - return(WaveFile); // Default. + + return( WaveFile ); // Default. } QString ProjectRenderer::getFileExtensionFromFormat( - ExportFileFormats fmt) + ExportFileFormats fmt ) { return fileEncodeDevices[fmt].m_extension; } @@ -147,33 +149,32 @@ QString ProjectRenderer::getFileExtensionFromFormat( void ProjectRenderer::startProcessing() { - if(isReady()) + if( isReady() ) { // Have to do mixer stuff with GUI-thread affinity in order to // make slots connected to sampleRateChanged()-signals being called immediately. - Engine::mixer()->setAudioDevice(m_fileDev, - m_qualitySettings, false); + Engine::mixer()->setAudioDevice( m_fileDev, + m_qualitySettings, false); start( #ifndef LMMS_BUILD_WIN32 - QThread::HighPriority + QThread::HighPriority #endif -); + ); + } } - - void ProjectRenderer::run() { #if 0 #ifdef LMMS_BUILD_LINUX #ifdef LMMS_HAVE_SCHED_H cpu_set_t mask; - CPU_ZERO(&mask); - CPU_SET(0, &mask); - sched_setaffinity(0, sizeof(mask), &mask); + CPU_ZERO( &mask ); + CPU_SET( 0, &mask ); + sched_setaffinity( 0, sizeof( mask ), &mask ); #endif #endif #endif @@ -184,7 +185,7 @@ void ProjectRenderer::run() Engine::mixer()->nextBuffer(); const Song::PlayPos & exportPos = Engine::getSong()->getPlayPos( - Song::Mode_PlaySong); + Song::Mode_PlaySong ); m_progress = 0; std::pair exportEndpoints = Engine::getSong()->getExportEndpoints(); tick_t startTick = exportEndpoints.first.getTicks(); @@ -192,16 +193,16 @@ void ProjectRenderer::run() tick_t lengthTicks = endTick - startTick; // Continually track and emit progress percentage to listeners. - while(exportPos.getTicks() < endTick && - Engine::getSong()->isExporting() == true - && !m_abort) + while( exportPos.getTicks() < endTick && + Engine::getSong()->isExporting() == true + && !m_abort ) { m_fileDev->processNextBuffer(); - const int nprog = lengthTicks == 0 ? 100 : (exportPos.getTicks()-startTick) * 100 / lengthTicks; - if(m_progress != nprog) + const int nprog = lengthTicks == 0 ? 100 : ( exportPos.getTicks()-startTick) * 100 / lengthTicks; + if( m_progress != nprog ) { m_progress = nprog; - emit progressChanged(m_progress); + emit progressChanged( m_progress ); } } @@ -212,9 +213,9 @@ void ProjectRenderer::run() // If the user aborted export-process, the file has to be deleted. const QString f = m_fileDev->outputFile(); - if(m_abort) + if( m_abort ) { - QFile(f).remove(); + QFile( f ).remove(); } } @@ -237,18 +238,20 @@ void ProjectRenderer::updateConsoleProgress() char buf[80]; char prog[cols+1]; - for(int i = 0; i < cols; ++i) + for( int i = 0; i < cols; ++i ) { - prog[i] = (i*100/cols <= m_progress ? '-' : ' '); + prog[i] = ( i*100/cols <= m_progress ? '-' : ' ' ); } prog[cols] = 0; - const char * activity = (const char *) "|/-\\"; - memset(buf, 0, sizeof(buf)); - sprintf(buf, "\r|%s| %3d%% %c ", prog, m_progress, - activity[rot]); - rot = (rot+1) % 4; + const char * activity = ( const char * ) "|/-\\"; + memset( buf, 0, sizeof( buf ) ); + sprintf( buf, "\r|%s| %3d%% %c ", prog, m_progress, + activity[rot] ); + rot = ( rot+1 ) % 4; - fprintf(stderr, "%s", buf); - fflush(stderr); + fprintf( stderr, "%s", buf ); + fflush( stderr ); } + + diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp index 477f7cb2a50..3ece7238373 100644 --- a/src/gui/AboutDialog.cpp +++ b/src/gui/AboutDialog.cpp @@ -29,34 +29,35 @@ #include "versioninfo.h" + AboutDialog::AboutDialog(QWidget* parent) : QDialog(parent), Ui::AboutDialog() { - setupUi(this); + setupUi( this ); - iconLabel->setPixmap(embed::getIconPixmap("icon", 64, 64)); + iconLabel->setPixmap( embed::getIconPixmap( "icon", 64, 64 ) ); - versionLabel->setText(versionLabel->text(). - arg(LMMS_VERSION). - arg(PLATFORM). - arg(MACHINE). - arg(QT_VERSION_STR). - arg(GCC_VERSION)); + versionLabel->setText( versionLabel->text(). + arg( LMMS_VERSION ). + arg( PLATFORM ). + arg( MACHINE ). + arg( QT_VERSION_STR ). + arg( GCC_VERSION ) ); versionLabel->setTextInteractionFlags( - versionLabel->textInteractionFlags() | - Qt::TextSelectableByMouse); + versionLabel->textInteractionFlags() | + Qt::TextSelectableByMouse ); - copyrightLabel->setText(copyrightLabel->text(). - arg(LMMS_PROJECT_COPYRIGHT)); + copyrightLabel->setText( copyrightLabel->text(). + arg( LMMS_PROJECT_COPYRIGHT ) ); authorLabel->setPlainText( - embed::getText("AUTHORS")); + embed::getText( "AUTHORS" ) ); /*involvedLabel->setPlainText( - embed::getText("CONTRIBUTORS"));*/ + embed::getText( "CONTRIBUTORS" ) );*/ licenseLabel->setPlainText( - embed::getText("LICENSE.txt")); -} + embed::getText( "LICENSE.txt" ) ); +} \ No newline at end of file diff --git a/src/gui/ExportProjectDialog.cpp b/src/gui/ExportProjectDialog.cpp index efa1ff3e802..1f34946e13f 100644 --- a/src/gui/ExportProjectDialog.cpp +++ b/src/gui/ExportProjectDialog.cpp @@ -22,7 +22,6 @@ * */ - #include #include #include @@ -35,113 +34,110 @@ #include "OutputSettings.h" -ExportProjectDialog::ExportProjectDialog(const QString & _file_name, - QWidget * _parent, bool multi_export=false) : - QDialog(_parent), +ExportProjectDialog::ExportProjectDialog( const QString & _file_name, + QWidget * _parent, bool multi_export=false ) : + QDialog( _parent ), Ui::ExportProjectDialog(), - m_fileName(_file_name), + m_fileName( _file_name ), m_fileExtension(), - m_multiExport(multi_export), - m_renderManager(nullptr) + m_multiExport( multi_export ), + m_renderManager( nullptr ) { - setupUi(this); - setWindowTitle(tr("Export project to %1").arg( - QFileInfo(_file_name).fileName())); + setupUi( this ); + setWindowTitle( tr( "Export project to %1" ).arg( + QFileInfo( _file_name ).fileName() ) ); // Get the extension of the chosen file. - QStringList parts = _file_name.split('.'); + QStringList parts = _file_name.split( '.' ); QString fileExt; - if(parts.size() > 0) + if( parts.size() > 0 ) { fileExt = "." + parts[parts.size()-1]; } int cbIndex = 0; - for(int i = 0; i < ProjectRenderer::NumFileFormats; ++i) + for( int i = 0; i < ProjectRenderer::NumFileFormats; ++i ) { - if(ProjectRenderer::fileEncodeDevices[i].isAvailable()) + if( ProjectRenderer::fileEncodeDevices[i].isAvailable() ) { // Get the extension of this format. QString renderExt = ProjectRenderer::fileEncodeDevices[i].m_extension; // Add to combo box. - fileFormatCB->addItem(ProjectRenderer::tr( - ProjectRenderer::fileEncodeDevices[i].m_description), - QVariant(ProjectRenderer::fileEncodeDevices[i].m_fileFormat) // Format tag; later used for identification. + fileFormatCB->addItem( ProjectRenderer::tr( + ProjectRenderer::fileEncodeDevices[i].m_description ), + QVariant( ProjectRenderer::fileEncodeDevices[i].m_fileFormat ) // Format tag; later used for identification. ); // If this is our extension, select it. - if(QString::compare(renderExt, fileExt, - Qt::CaseInsensitive) == 0) + if( QString::compare( renderExt, fileExt, + Qt::CaseInsensitive ) == 0 ) { - fileFormatCB->setCurrentIndex(cbIndex); + fileFormatCB->setCurrentIndex( cbIndex ); } + cbIndex++; } } int const MAX_LEVEL=8; - for(int i=0; i<=MAX_LEVEL; ++i) + for( int i=0; i<=MAX_LEVEL; ++i ) { QString info=""; - if (i==0){ info = tr("(Fastest - biggest)"); } - else if (i==MAX_LEVEL){ info = tr("(Slowest - smallest)"); } + if ( i==0 ){ info = tr( "( Fastest - biggest )" ); } + else if ( i==MAX_LEVEL ){ info = tr( "( Slowest - smallest )" ); } compLevelCB->addItem( - QString::number(i)+" "+info, - QVariant(i/static_cast(MAX_LEVEL)) + QString::number( i )+" "+info, + QVariant( i/static_cast( MAX_LEVEL ) ) ); } - compLevelCB->setCurrentIndex(MAX_LEVEL/2); + compLevelCB->setCurrentIndex( MAX_LEVEL/2 ); #ifndef LMMS_HAVE_SF_COMPLEVEL // Disable this widget; the setting would be ignored by the renderer. - compressionWidget->setVisible(false); + compressionWidget->setVisible( false ); #endif - connect(startButton, SIGNAL(clicked()), - this, SLOT(startBtnClicked())); + connect( startButton, SIGNAL( clicked() ), + this, SLOT( startBtnClicked() ) ); } - - void ExportProjectDialog::reject() { - if(m_renderManager) { + if( m_renderManager ) { m_renderManager->abortProcessing(); } - m_renderManager.reset(nullptr); + m_renderManager.reset( nullptr ); QDialog::reject(); } - void ExportProjectDialog::accept() { - m_renderManager.reset(nullptr); + m_renderManager.reset( nullptr ); QDialog::accept(); } -void ExportProjectDialog::closeEvent(QCloseEvent * _ce) +void ExportProjectDialog::closeEvent( QCloseEvent * _ce ) { - if(m_renderManager) + if( m_renderManager ) { m_renderManager->abortProcessing(); } - QDialog::closeEvent(_ce); -} - + QDialog::closeEvent( _ce ); +} -OutputSettings::StereoMode mapToStereoMode(int index) +OutputSettings::StereoMode mapToStereoMode( int index ) { - switch (index) + switch ( index ) { case 0: return OutputSettings::StereoMode_Stereo; @@ -154,56 +150,53 @@ OutputSettings::StereoMode mapToStereoMode(int index) } } - - - void ExportProjectDialog::startExport() { Mixer::qualitySettings qs = Mixer::qualitySettings( - static_cast(interpolationCB->currentIndex()), - static_cast(oversamplingCB->currentIndex())); + static_cast( interpolationCB->currentIndex() ), + static_cast( oversamplingCB->currentIndex() ) ); const int samplerates[5] = { 44100, 48000, 88200, 96000, 192000 }; const bitrate_t bitrates[6] = { 64, 128, 160, 192, 256, 320 }; bool useVariableBitRate = checkBoxVariableBitRate->isChecked(); - OutputSettings::BitRateSettings bitRateSettings(bitrates[ bitrateCB->currentIndex() ], useVariableBitRate); + OutputSettings::BitRateSettings bitRateSettings( bitrates[ bitrateCB->currentIndex() ], useVariableBitRate ); OutputSettings os = OutputSettings( samplerates[ samplerateCB->currentIndex() ], bitRateSettings, - static_cast(depthCB->currentIndex()), - mapToStereoMode(stereoModeComboBox->currentIndex())); + static_cast( depthCB->currentIndex() ), + mapToStereoMode( stereoModeComboBox->currentIndex() ) ); - if (compressionWidget->isVisible()) + if ( compressionWidget->isVisible() ) { - double level = compLevelCB->itemData(compLevelCB->currentIndex()).toDouble(); - os.setCompressionLevel(level); + double level = compLevelCB->itemData( compLevelCB->currentIndex() ).toDouble(); + os.setCompressionLevel( level ); } // Make sure we have the the correct file extension // so there's no confusion about the codec in use. auto output_name = m_fileName; - if (!(m_multiExport || output_name.endsWith(m_fileExtension,Qt::CaseInsensitive))) + if ( !( m_multiExport || output_name.endsWith( m_fileExtension,Qt::CaseInsensitive ) ) ) { output_name+=m_fileExtension; } - m_renderManager.reset(new RenderManager(qs, os, m_ft, output_name)); + m_renderManager.reset( new RenderManager( qs, os, m_ft, output_name ) ); - Engine::getSong()->setExportLoop(exportLoopCB->isChecked()); - Engine::getSong()->setRenderBetweenMarkers(renderMarkersCB->isChecked()); + Engine::getSong()->setExportLoop( exportLoopCB->isChecked() ); + Engine::getSong()->setRenderBetweenMarkers( renderMarkersCB->isChecked() ); - connect(m_renderManager.get(), SIGNAL(progressChanged(int)), - progressBar, SLOT(setValue(int))); - connect(m_renderManager.get(), SIGNAL(progressChanged(int)), - this, SLOT(updateTitleBar(int))); - connect(m_renderManager.get(), SIGNAL(finished()), - this, SLOT(accept())); - connect(m_renderManager.get(), SIGNAL(finished()), - gui->mainWindow(), SLOT(resetWindowTitle())); + connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), + progressBar, SLOT( setValue( int ) ) ); + connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), + this, SLOT( updateTitleBar( int ) ) ); + connect( m_renderManager.get(), SIGNAL( finished() ), + this, SLOT( accept() ) ); + connect( m_renderManager.get(), SIGNAL( finished() ), + gui->mainWindow(), SLOT( resetWindowTitle() ) ); - if (m_multiExport) + if ( m_multiExport ) { m_renderManager->renderTracks(); } @@ -214,83 +207,78 @@ void ExportProjectDialog::startExport() } - - -void ExportProjectDialog::onFileFormatChanged(int index) +void ExportProjectDialog::onFileFormatChanged( int index ) { // Extract the format tag from the currently selected item, // and adjust the UI properly. - QVariant format_tag = fileFormatCB->itemData(index); + QVariant format_tag = fileFormatCB->itemData( index ); bool successful_conversion = false; auto exportFormat = static_cast( - format_tag.toInt(&successful_conversion) + format_tag.toInt( &successful_conversion ) ); - Q_ASSERT(successful_conversion); + Q_ASSERT( successful_conversion ); - bool stereoModeVisible = (exportFormat == ProjectRenderer::MP3File); + bool stereoModeVisible = ( exportFormat == ProjectRenderer::MP3File ); - bool sampleRateControlsVisible = (exportFormat != ProjectRenderer::MP3File); + bool sampleRateControlsVisible = ( exportFormat != ProjectRenderer::MP3File ); bool bitRateControlsEnabled = - (exportFormat == ProjectRenderer::OggFile || - exportFormat == ProjectRenderer::MP3File); + ( exportFormat == ProjectRenderer::OggFile || + exportFormat == ProjectRenderer::MP3File ); bool bitDepthControlEnabled = - (exportFormat == ProjectRenderer::WaveFile || - exportFormat == ProjectRenderer::FlacFile); + ( exportFormat == ProjectRenderer::WaveFile || + exportFormat == ProjectRenderer::FlacFile ); - bool variableBitrateVisible = !(exportFormat == ProjectRenderer::MP3File || exportFormat == ProjectRenderer::FlacFile); + bool variableBitrateVisible = !( exportFormat == ProjectRenderer::MP3File || exportFormat == ProjectRenderer::FlacFile ); #ifdef LMMS_HAVE_SF_COMPLEVEL - bool compressionLevelVisible = (exportFormat == ProjectRenderer::FlacFile); - compressionWidget->setVisible(compressionLevelVisible); + bool compressionLevelVisible = ( exportFormat == ProjectRenderer::FlacFile ); + compressionWidget->setVisible( compressionLevelVisible ); #endif - stereoModeWidget->setVisible(stereoModeVisible); - sampleRateWidget->setVisible(sampleRateControlsVisible); + stereoModeWidget->setVisible( stereoModeVisible ); + sampleRateWidget->setVisible( sampleRateControlsVisible ); - bitrateWidget->setVisible(bitRateControlsEnabled); - checkBoxVariableBitRate->setVisible(variableBitrateVisible); + bitrateWidget->setVisible( bitRateControlsEnabled ); + checkBoxVariableBitRate->setVisible( variableBitrateVisible ); - depthWidget->setVisible(bitDepthControlEnabled); + depthWidget->setVisible( bitDepthControlEnabled ); } - - - void ExportProjectDialog::startBtnClicked() { m_ft = ProjectRenderer::NumFileFormats; // Get file format from current menu selection. bool successful_conversion = false; - QVariant tag = fileFormatCB->itemData(fileFormatCB->currentIndex()); + QVariant tag = fileFormatCB->itemData( fileFormatCB->currentIndex() ); m_ft = static_cast( - tag.toInt(&successful_conversion)); + tag.toInt( &successful_conversion ) ); - if(!successful_conversion) + if( !successful_conversion ) { - QMessageBox::information(this, tr("Error"), - tr("Error while determining file-encoder device. " + QMessageBox::information( this, tr( "Error" ), + tr( "Error while determining file-encoder device. " "Please try to choose a different output " - "format.")); + "format." ) ); reject(); return; } // Find proper file extension. - for(int i = 0; i < ProjectRenderer::NumFileFormats; ++i) + for( int i = 0; i < ProjectRenderer::NumFileFormats; ++i ) { - if (m_ft == ProjectRenderer::fileEncodeDevices[i].m_fileFormat) + if ( m_ft == ProjectRenderer::fileEncodeDevices[i].m_fileFormat ) { - m_fileExtension = QString(QLatin1String(ProjectRenderer::fileEncodeDevices[i].m_extension)); + m_fileExtension = QString( QLatin1String( ProjectRenderer::fileEncodeDevices[i].m_extension ) ); break; } } - startButton->setEnabled(false); - progressBar->setEnabled(true); + startButton->setEnabled( false ); + progressBar->setEnabled( true ); - updateTitleBar(0); + updateTitleBar( 0 ); startExport(); } @@ -298,8 +286,8 @@ void ExportProjectDialog::startBtnClicked() -void ExportProjectDialog::updateTitleBar(int _prog) +void ExportProjectDialog::updateTitleBar( int _prog ) { gui->mainWindow()->setWindowTitle( - tr("Rendering: %1%").arg(_prog)); -} + tr( "Rendering: %1%" ).arg( _prog ) ); +} \ No newline at end of file From 015f4c966c0d9b35a52730d619b211394c09e055 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Wed, 27 Sep 2017 15:55:17 +0300 Subject: [PATCH 07/14] Formatting reverse 2. --- src/core/ProjectRenderer.cpp | 12 ++--- src/gui/AboutDialog.cpp | 11 ++--- src/gui/ExportProjectDialog.cpp | 82 ++++++++++++++++----------------- 3 files changed, 51 insertions(+), 54 deletions(-) diff --git a/src/core/ProjectRenderer.cpp b/src/core/ProjectRenderer.cpp index 0b19f72b273..74354902246 100644 --- a/src/core/ProjectRenderer.cpp +++ b/src/core/ProjectRenderer.cpp @@ -56,7 +56,7 @@ const ProjectRenderer::FileEncodeDevice ProjectRenderer::fileEncodeDevices[] = #else NULL #endif - }, + }, { ProjectRenderer::MP3File, QT_TRANSLATE_NOOP( "ProjectRenderer", "MP3 (*.mp3)" ), ".mp3", @@ -65,7 +65,7 @@ const ProjectRenderer::FileEncodeDevice ProjectRenderer::fileEncodeDevices[] = #else NULL #endif - }, + }, // Insert your own file-encoder infos here. // Maybe one day the user can add own encoders inside the program. @@ -89,7 +89,7 @@ ProjectRenderer::ProjectRenderer( const Mixer::qualitySettings & qualitySettings { AudioFileDeviceInstantiaton audioEncoderFactory = fileEncodeDevices[exportFileFormat].m_getDevInst; - if ( audioEncoderFactory ) + if (audioEncoderFactory) { bool successful = false; @@ -154,7 +154,7 @@ void ProjectRenderer::startProcessing() // Have to do mixer stuff with GUI-thread affinity in order to // make slots connected to sampleRateChanged()-signals being called immediately. Engine::mixer()->setAudioDevice( m_fileDev, - m_qualitySettings, false); + m_qualitySettings, false ); start( #ifndef LMMS_BUILD_WIN32 @@ -198,7 +198,7 @@ void ProjectRenderer::run() && !m_abort ) { m_fileDev->processNextBuffer(); - const int nprog = lengthTicks == 0 ? 100 : ( exportPos.getTicks()-startTick) * 100 / lengthTicks; + const int nprog = lengthTicks == 0 ? 100 : (exportPos.getTicks()-startTick) * 100 / lengthTicks; if( m_progress != nprog ) { m_progress = nprog; @@ -247,7 +247,7 @@ void ProjectRenderer::updateConsoleProgress() const char * activity = ( const char * ) "|/-\\"; memset( buf, 0, sizeof( buf ) ); sprintf( buf, "\r|%s| %3d%% %c ", prog, m_progress, - activity[rot] ); + activity[rot] ); rot = ( rot+1 ) % 4; fprintf( stderr, "%s", buf ); diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp index 3ece7238373..887b6b6b166 100644 --- a/src/gui/AboutDialog.cpp +++ b/src/gui/AboutDialog.cpp @@ -52,12 +52,9 @@ AboutDialog::AboutDialog(QWidget* parent) : copyrightLabel->setText( copyrightLabel->text(). arg( LMMS_PROJECT_COPYRIGHT ) ); - authorLabel->setPlainText( - embed::getText( "AUTHORS" ) ); + authorLabel->setPlainText( embed::getText( "AUTHORS" ) ); - /*involvedLabel->setPlainText( - embed::getText( "CONTRIBUTORS" ) );*/ + /*involvedLabel->setPlainText( embed::getText( "CONTRIBUTORS" ) );*/ - licenseLabel->setPlainText( - embed::getText( "LICENSE.txt" ) ); -} \ No newline at end of file + licenseLabel->setPlainText( embed::getText( "LICENSE.txt" ) ); +} diff --git a/src/gui/ExportProjectDialog.cpp b/src/gui/ExportProjectDialog.cpp index 1f34946e13f..63269c04117 100644 --- a/src/gui/ExportProjectDialog.cpp +++ b/src/gui/ExportProjectDialog.cpp @@ -35,7 +35,7 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, - QWidget * _parent, bool multi_export=false ) : + QWidget * _parent, bool multi_export=false ) : QDialog( _parent ), Ui::ExportProjectDialog(), m_fileName( _file_name ), @@ -81,7 +81,7 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, } int const MAX_LEVEL=8; - for( int i=0; i<=MAX_LEVEL; ++i ) + for(int i=0; i<=MAX_LEVEL; ++i) { QString info=""; if ( i==0 ){ info = tr( "( Fastest - biggest )" ); } @@ -89,13 +89,13 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, compLevelCB->addItem( QString::number( i )+" "+info, - QVariant( i/static_cast( MAX_LEVEL ) ) + QVariant(i/static_cast(MAX_LEVEL)) ); } - compLevelCB->setCurrentIndex( MAX_LEVEL/2 ); + compLevelCB->setCurrentIndex(MAX_LEVEL/2); #ifndef LMMS_HAVE_SF_COMPLEVEL // Disable this widget; the setting would be ignored by the renderer. - compressionWidget->setVisible( false ); + compressionWidget->setVisible(false); #endif connect( startButton, SIGNAL( clicked() ), @@ -117,7 +117,7 @@ void ExportProjectDialog::reject() void ExportProjectDialog::accept() { - m_renderManager.reset( nullptr ); + m_renderManager.reset(nullptr); QDialog::accept(); } @@ -126,8 +126,7 @@ void ExportProjectDialog::accept() void ExportProjectDialog::closeEvent( QCloseEvent * _ce ) { - if( m_renderManager ) - { + if( m_renderManager ) { m_renderManager->abortProcessing(); } @@ -135,9 +134,9 @@ void ExportProjectDialog::closeEvent( QCloseEvent * _ce ) } -OutputSettings::StereoMode mapToStereoMode( int index ) +OutputSettings::StereoMode mapToStereoMode(int index) { - switch ( index ) + switch (index) { case 0: return OutputSettings::StereoMode_Stereo; @@ -154,35 +153,35 @@ void ExportProjectDialog::startExport() { Mixer::qualitySettings qs = Mixer::qualitySettings( - static_cast( interpolationCB->currentIndex() ), - static_cast( oversamplingCB->currentIndex() ) ); + static_cast(interpolationCB->currentIndex()), + static_cast(oversamplingCB->currentIndex()) ); const int samplerates[5] = { 44100, 48000, 88200, 96000, 192000 }; const bitrate_t bitrates[6] = { 64, 128, 160, 192, 256, 320 }; bool useVariableBitRate = checkBoxVariableBitRate->isChecked(); - OutputSettings::BitRateSettings bitRateSettings( bitrates[ bitrateCB->currentIndex() ], useVariableBitRate ); + OutputSettings::BitRateSettings bitRateSettings(bitrates[ bitrateCB->currentIndex() ], useVariableBitRate); OutputSettings os = OutputSettings( samplerates[ samplerateCB->currentIndex() ], bitRateSettings, static_cast( depthCB->currentIndex() ), - mapToStereoMode( stereoModeComboBox->currentIndex() ) ); + mapToStereoMode(stereoModeComboBox->currentIndex()) ); - if ( compressionWidget->isVisible() ) + if (compressionWidget->isVisible()) { - double level = compLevelCB->itemData( compLevelCB->currentIndex() ).toDouble(); - os.setCompressionLevel( level ); + double level = compLevelCB->itemData(compLevelCB->currentIndex()).toDouble(); + os.setCompressionLevel(level); } // Make sure we have the the correct file extension // so there's no confusion about the codec in use. auto output_name = m_fileName; - if ( !( m_multiExport || output_name.endsWith( m_fileExtension,Qt::CaseInsensitive ) ) ) + if (!(m_multiExport || output_name.endsWith( m_fileExtension,Qt::CaseInsensitive))) { output_name+=m_fileExtension; } - m_renderManager.reset( new RenderManager( qs, os, m_ft, output_name ) ); + m_renderManager.reset(new RenderManager( qs, os, m_ft, output_name )); Engine::getSong()->setExportLoop( exportLoopCB->isChecked() ); Engine::getSong()->setRenderBetweenMarkers( renderMarkersCB->isChecked() ); @@ -190,7 +189,7 @@ void ExportProjectDialog::startExport() connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), progressBar, SLOT( setValue( int ) ) ); connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), - this, SLOT( updateTitleBar( int ) ) ); + this, SLOT( updateTitleBar( int ) )); connect( m_renderManager.get(), SIGNAL( finished() ), this, SLOT( accept() ) ); connect( m_renderManager.get(), SIGNAL( finished() ), @@ -207,43 +206,43 @@ void ExportProjectDialog::startExport() } -void ExportProjectDialog::onFileFormatChanged( int index ) +void ExportProjectDialog::onFileFormatChanged(int index) { // Extract the format tag from the currently selected item, // and adjust the UI properly. - QVariant format_tag = fileFormatCB->itemData( index ); + QVariant format_tag = fileFormatCB->itemData(index); bool successful_conversion = false; auto exportFormat = static_cast( - format_tag.toInt( &successful_conversion ) + format_tag.toInt(&successful_conversion) ); - Q_ASSERT( successful_conversion ); + Q_ASSERT(successful_conversion); - bool stereoModeVisible = ( exportFormat == ProjectRenderer::MP3File ); + bool stereoModeVisible = (exportFormat == ProjectRenderer::MP3File); - bool sampleRateControlsVisible = ( exportFormat != ProjectRenderer::MP3File ); + bool sampleRateControlsVisible = (exportFormat != ProjectRenderer::MP3File); bool bitRateControlsEnabled = - ( exportFormat == ProjectRenderer::OggFile || - exportFormat == ProjectRenderer::MP3File ); + (exportFormat == ProjectRenderer::OggFile || + exportFormat == ProjectRenderer::MP3File); bool bitDepthControlEnabled = - ( exportFormat == ProjectRenderer::WaveFile || - exportFormat == ProjectRenderer::FlacFile ); + (exportFormat == ProjectRenderer::WaveFile || + exportFormat == ProjectRenderer::FlacFile); bool variableBitrateVisible = !( exportFormat == ProjectRenderer::MP3File || exportFormat == ProjectRenderer::FlacFile ); #ifdef LMMS_HAVE_SF_COMPLEVEL - bool compressionLevelVisible = ( exportFormat == ProjectRenderer::FlacFile ); - compressionWidget->setVisible( compressionLevelVisible ); + bool compressionLevelVisible = (exportFormat == ProjectRenderer::FlacFile); + compressionWidget->setVisible(compressionLevelVisible); #endif - stereoModeWidget->setVisible( stereoModeVisible ); - sampleRateWidget->setVisible( sampleRateControlsVisible ); + stereoModeWidget->setVisible(stereoModeVisible); + sampleRateWidget->setVisible(sampleRateControlsVisible); - bitrateWidget->setVisible( bitRateControlsEnabled ); - checkBoxVariableBitRate->setVisible( variableBitrateVisible ); + bitrateWidget->setVisible(bitRateControlsEnabled); + checkBoxVariableBitRate->setVisible(variableBitrateVisible); - depthWidget->setVisible( bitDepthControlEnabled ); + depthWidget->setVisible(bitDepthControlEnabled); } void ExportProjectDialog::startBtnClicked() @@ -252,9 +251,10 @@ void ExportProjectDialog::startBtnClicked() // Get file format from current menu selection. bool successful_conversion = false; - QVariant tag = fileFormatCB->itemData( fileFormatCB->currentIndex() ); + QVariant tag = fileFormatCB->itemData(fileFormatCB->currentIndex()); m_ft = static_cast( - tag.toInt( &successful_conversion ) ); + tag.toInt( &successful_conversion ) + ); if( !successful_conversion ) { @@ -269,7 +269,7 @@ void ExportProjectDialog::startBtnClicked() // Find proper file extension. for( int i = 0; i < ProjectRenderer::NumFileFormats; ++i ) { - if ( m_ft == ProjectRenderer::fileEncodeDevices[i].m_fileFormat ) + if (m_ft == ProjectRenderer::fileEncodeDevices[i].m_fileFormat) { m_fileExtension = QString( QLatin1String( ProjectRenderer::fileEncodeDevices[i].m_extension ) ); break; @@ -290,4 +290,4 @@ void ExportProjectDialog::updateTitleBar( int _prog ) { gui->mainWindow()->setWindowTitle( tr( "Rendering: %1%" ).arg( _prog ) ); -} \ No newline at end of file +} From 080c8b493326b9fbf5c2a65c3536c9563a56896f Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Wed, 27 Sep 2017 16:08:02 +0300 Subject: [PATCH 08/14] Formatting reverse 3. --- src/core/ProjectRenderer.cpp | 5 ++--- src/gui/ExportProjectDialog.cpp | 13 +++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/core/ProjectRenderer.cpp b/src/core/ProjectRenderer.cpp index 74354902246..303369f3400 100644 --- a/src/core/ProjectRenderer.cpp +++ b/src/core/ProjectRenderer.cpp @@ -44,7 +44,7 @@ const ProjectRenderer::FileEncodeDevice ProjectRenderer::fileEncodeDevices[] = QT_TRANSLATE_NOOP( "ProjectRenderer", "WAV (*.wav)" ), ".wav", &AudioFileWave::getInst }, { ProjectRenderer::FlacFile, - QT_TRANSLATE_NOOP( "ProjectRenderer", "FLAC (*.flac)" ), + QT_TRANSLATE_NOOP("ProjectRenderer", "FLAC (*.flac)"), ".flac", &AudioFileFlac::getInst }, @@ -230,7 +230,6 @@ void ProjectRenderer::abortProcessing() - void ProjectRenderer::updateConsoleProgress() { const int cols = 50; @@ -244,7 +243,7 @@ void ProjectRenderer::updateConsoleProgress() } prog[cols] = 0; - const char * activity = ( const char * ) "|/-\\"; + const char * activity = (const char *) "|/-\\"; memset( buf, 0, sizeof( buf ) ); sprintf( buf, "\r|%s| %3d%% %c ", prog, m_progress, activity[rot] ); diff --git a/src/gui/ExportProjectDialog.cpp b/src/gui/ExportProjectDialog.cpp index 63269c04117..f0a013dcfec 100644 --- a/src/gui/ExportProjectDialog.cpp +++ b/src/gui/ExportProjectDialog.cpp @@ -88,7 +88,7 @@ ExportProjectDialog::ExportProjectDialog( const QString & _file_name, else if ( i==MAX_LEVEL ){ info = tr( "( Slowest - smallest )" ); } compLevelCB->addItem( - QString::number( i )+" "+info, + QString::number(i)+" "+info, QVariant(i/static_cast(MAX_LEVEL)) ); } @@ -108,7 +108,7 @@ void ExportProjectDialog::reject() if( m_renderManager ) { m_renderManager->abortProcessing(); } - m_renderManager.reset( nullptr ); + m_renderManager.reset(nullptr); QDialog::reject(); } @@ -177,7 +177,7 @@ void ExportProjectDialog::startExport() // Make sure we have the the correct file extension // so there's no confusion about the codec in use. auto output_name = m_fileName; - if (!(m_multiExport || output_name.endsWith( m_fileExtension,Qt::CaseInsensitive))) + if (!(m_multiExport || output_name.endsWith(m_fileExtension,Qt::CaseInsensitive))) { output_name+=m_fileExtension; } @@ -191,7 +191,7 @@ void ExportProjectDialog::startExport() connect( m_renderManager.get(), SIGNAL( progressChanged( int ) ), this, SLOT( updateTitleBar( int ) )); connect( m_renderManager.get(), SIGNAL( finished() ), - this, SLOT( accept() ) ); + this, SLOT( accept() ) ) ; connect( m_renderManager.get(), SIGNAL( finished() ), gui->mainWindow(), SLOT( resetWindowTitle() ) ); @@ -229,7 +229,7 @@ void ExportProjectDialog::onFileFormatChanged(int index) (exportFormat == ProjectRenderer::WaveFile || exportFormat == ProjectRenderer::FlacFile); - bool variableBitrateVisible = !( exportFormat == ProjectRenderer::MP3File || exportFormat == ProjectRenderer::FlacFile ); + bool variableBitrateVisible = !(exportFormat == ProjectRenderer::MP3File || exportFormat == ProjectRenderer::FlacFile); #ifdef LMMS_HAVE_SF_COMPLEVEL bool compressionLevelVisible = (exportFormat == ProjectRenderer::FlacFile); @@ -253,7 +253,7 @@ void ExportProjectDialog::startBtnClicked() bool successful_conversion = false; QVariant tag = fileFormatCB->itemData(fileFormatCB->currentIndex()); m_ft = static_cast( - tag.toInt( &successful_conversion ) + tag.toInt(&successful_conversion) ); if( !successful_conversion ) @@ -275,6 +275,7 @@ void ExportProjectDialog::startBtnClicked() break; } } + startButton->setEnabled( false ); progressBar->setEnabled( true ); From 4398747f4acc3914659703b33a2a4d076ab5dff1 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Wed, 27 Sep 2017 16:36:16 +0300 Subject: [PATCH 09/14] Return "Involved" tab. Revert AboutDialog.cpp changes. --- src/gui/AboutDialog.cpp | 4 ++-- src/gui/dialogs/about_dialog.ui | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/gui/AboutDialog.cpp b/src/gui/AboutDialog.cpp index 887b6b6b166..618d35966a8 100644 --- a/src/gui/AboutDialog.cpp +++ b/src/gui/AboutDialog.cpp @@ -54,7 +54,7 @@ AboutDialog::AboutDialog(QWidget* parent) : authorLabel->setPlainText( embed::getText( "AUTHORS" ) ); - /*involvedLabel->setPlainText( embed::getText( "CONTRIBUTORS" ) );*/ - licenseLabel->setPlainText( embed::getText( "LICENSE.txt" ) ); + + involvedLabel->setPlainText( embed::getText( "CONTRIBUTORS" ) ); } diff --git a/src/gui/dialogs/about_dialog.ui b/src/gui/dialogs/about_dialog.ui index 6930b402e67..63b265d31bf 100644 --- a/src/gui/dialogs/about_dialog.ui +++ b/src/gui/dialogs/about_dialog.ui @@ -204,7 +204,6 @@ - Translation From 351c8ca59340db7ef43830cb4d3ed3b1f09fa9cb Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Sat, 30 Sep 2017 13:02:39 +0300 Subject: [PATCH 10/14] Commented out "Export as loop". --- src/gui/dialogs/export_project.ui | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index 7985baab666..bb6c5e5c468 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -6,13 +6,13 @@ 0 0 - 374 + 379 374 - 374 + 379 374 @@ -20,6 +20,7 @@ Export project + From 10f4924973be60e6ba74694d2d96342de05127b5 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Sat, 30 Sep 2017 13:24:16 +0300 Subject: [PATCH 11/14] Undo commented out "Export as loop". --- src/gui/dialogs/export_project.ui | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index bb6c5e5c468..08c9a47f770 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -20,7 +20,6 @@ Export project - From 9da7ae6a6e05e1dd06c92055fbcc54a840192130 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Thu, 26 Oct 2017 17:37:01 +0300 Subject: [PATCH 12/14] ED: (Remove end silence) -> (Remove extra bar). --- src/gui/dialogs/export_project.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index 08c9a47f770..12fa85c214e 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -23,7 +23,7 @@ - Export as loop (remove end silence) + Export as loop (remove extra bar) From bb43f97f8d0288ee65f2ec2103ef990a1bf63372 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Fri, 27 Oct 2017 13:41:35 +0300 Subject: [PATCH 13/14] Export dialog should not be resizable. --- src/gui/dialogs/export_project.ui | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/gui/dialogs/export_project.ui b/src/gui/dialogs/export_project.ui index 12fa85c214e..c8ea5cf2065 100644 --- a/src/gui/dialogs/export_project.ui +++ b/src/gui/dialogs/export_project.ui @@ -16,6 +16,12 @@ 374 + + + 379 + 374 + + Export project From aa589fa23f322e2c1911cbd95f5944bc5e632f36 Mon Sep 17 00:00:00 2001 From: Hussam Eddin Alhomsi Date: Sat, 4 Nov 2017 13:23:20 +0300 Subject: [PATCH 14/14] "LMMS developers" to "LMMS Developers". --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 22291d6567d..8c8c48eeb4f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,7 +22,7 @@ STRING(TOUPPER "${CMAKE_PROJECT_NAME}" PROJECT_NAME_UCASE) # Updated by maintenance tasks SET(PROJECT_YEAR 2015) -SET(PROJECT_AUTHOR "LMMS developers") +SET(PROJECT_AUTHOR "LMMS Developers") SET(PROJECT_URL "https://lmms.io") SET(PROJECT_EMAIL "lmms-devel@lists.sourceforge.net") SET(PROJECT_DESCRIPTION "${PROJECT_NAME_UCASE} - Free music production software")