update main-window title-bar while rendering
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@965 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
2008-05-13 Tobias Doerffel <tobydox/at/users/dot/sourceforge/dot/net>
|
||||
|
||||
* include/export_project_dialog.h:
|
||||
* src/gui/export_project_dialog.cpp:
|
||||
update main-window title-bar while rendering
|
||||
|
||||
* src/gui/widgets/visualization_widget.cpp:
|
||||
do not update while song-export
|
||||
|
||||
|
||||
@@ -49,6 +49,7 @@ protected:
|
||||
|
||||
private slots:
|
||||
void startBtnClicked( void );
|
||||
void updateTitleBar( int );
|
||||
|
||||
|
||||
private:
|
||||
|
||||
@@ -29,6 +29,8 @@
|
||||
|
||||
|
||||
#include "export_project_dialog.h"
|
||||
#include "engine.h"
|
||||
#include "main_window.h"
|
||||
#include "project_renderer.h"
|
||||
|
||||
|
||||
@@ -91,6 +93,8 @@ void exportProjectDialog::startBtnClicked( void )
|
||||
startButton->setEnabled( FALSE );
|
||||
progressBar->setEnabled( TRUE );
|
||||
|
||||
updateTitleBar( 0 );
|
||||
|
||||
mixer::qualitySettings qs = mixer::qualitySettings(
|
||||
static_cast<mixer::qualitySettings::Interpolation>(
|
||||
interpolationCB->currentIndex() ),
|
||||
@@ -110,14 +114,27 @@ void exportProjectDialog::startBtnClicked( void )
|
||||
m_fileName );
|
||||
connect( m_renderer, SIGNAL( progressChanged( int ) ),
|
||||
progressBar, SLOT( setValue( int ) ) );
|
||||
connect( m_renderer, SIGNAL( progressChanged( int ) ),
|
||||
this, SLOT( updateTitleBar( int ) ) );
|
||||
connect( m_renderer, SIGNAL( finished() ),
|
||||
this, SLOT( accept() ) );
|
||||
connect( m_renderer, SIGNAL( finished() ),
|
||||
engine::getMainWindow(), SLOT( resetWindowTitle() ) );
|
||||
|
||||
m_renderer->startProcessing();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
void exportProjectDialog::updateTitleBar( int _prog )
|
||||
{
|
||||
engine::getMainWindow()->setWindowTitle(
|
||||
tr( "Rendering: %1%" ).arg( _prog ) );
|
||||
}
|
||||
|
||||
|
||||
|
||||
#include "export_project_dialog.moc"
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user