55 lines
2.0 KiB
C++
55 lines
2.0 KiB
C++
|
///////////////////////////////////////////////////////////////////////////////
|
||
|
// LameXP - Audio Encoder Front-End
|
||
|
// Copyright (C) 2004-2010 LoRd_MuldeR <MuldeR2@GMX.de>
|
||
|
//
|
||
|
// This program is free software; you can redistribute it and/or modify
|
||
|
// it under the terms of the GNU General Public License as published by
|
||
|
// the Free Software Foundation; either version 2 of the License, or
|
||
|
// (at your option) any later version.
|
||
|
//
|
||
|
// This program is distributed in the hope that it will be useful,
|
||
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
// GNU General Public License for more details.
|
||
|
//
|
||
|
// You should have received a copy of the GNU General Public License along
|
||
|
// with this program; if not, write to the Free Software Foundation, Inc.,
|
||
|
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||
|
//
|
||
|
// http://www.gnu.org/licenses/gpl-2.0.txt
|
||
|
///////////////////////////////////////////////////////////////////////////////
|
||
|
|
||
|
#include "Dialog_Processing.h"
|
||
|
|
||
|
#include "Global.h"
|
||
|
|
||
|
#include <QApplication>
|
||
|
#include <QRect>
|
||
|
#include <QDesktopWidget>
|
||
|
#include <QMovie>
|
||
|
|
||
|
ProcessingDialog::ProcessingDialog(void)
|
||
|
{
|
||
|
//Init the dialog, from the .ui file
|
||
|
setupUi(this);
|
||
|
setWindowFlags(windowFlags() ^ Qt::WindowContextHelpButtonHint);
|
||
|
label_versionInfo->setText(QString().sprintf("v%d.%02d %s (Build %d)", lamexp_version_major(), lamexp_version_minor(), lamexp_version_release(), lamexp_version_build()));
|
||
|
|
||
|
//Center window in screen
|
||
|
QRect desktopRect = QApplication::desktop()->screenGeometry();
|
||
|
QRect thisRect = this->geometry();
|
||
|
move((desktopRect.width() - thisRect.width()) / 2, (desktopRect.height() - thisRect.height()) / 2);
|
||
|
setMinimumSize(thisRect.width(), thisRect.height());
|
||
|
|
||
|
//Init progress indicator
|
||
|
m_progressIndicator = new QMovie(":/images/Working.gif");
|
||
|
label_headerWorking->setMovie(m_progressIndicator);
|
||
|
m_progressIndicator->start();
|
||
|
}
|
||
|
|
||
|
ProcessingDialog::~ProcessingDialog(void)
|
||
|
{
|
||
|
if(m_progressIndicator) m_progressIndicator->stop();
|
||
|
LAMEXP_DELETE(m_progressIndicator);
|
||
|
}
|