Implemented new "adaptive" Opus bitrate LUT.
[LameXP.git] / src / Dialog_About.h
blob931ddad53ce0465efd8b3eb6e8a6e9e2d848cbed
1 ///////////////////////////////////////////////////////////////////////////////
2 // LameXP - Audio Encoder Front-End
3 // Copyright (C) 2004-2018 LoRd_MuldeR <MuldeR2@GMX.de>
4 //
5 // This program is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation; either version 2 of the License, or
8 // (at your option) any later version, but always including the *additional*
9 // restrictions defined in the "License.txt" file.
11 // This program is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
16 // You should have received a copy of the GNU General Public License along
17 // with this program; if not, write to the Free Software Foundation, Inc.,
18 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20 // http://www.gnu.org/licenses/gpl-2.0.txt
21 ///////////////////////////////////////////////////////////////////////////////
23 #pragma once
25 #include <QDialog>
27 //UIC forward declartion
28 namespace Ui {
29 class AboutDialog;
32 //Class declarations
33 class QLabel;
34 class QPixmap;
35 class QTimer;
36 class QElapsedTimer;
37 class SettingsModel;
39 //AboutDialog class
40 class AboutDialog : public QDialog
42 Q_OBJECT
44 public:
45 AboutDialog(SettingsModel *settings, QWidget *parent = 0, bool firstStart = false);
46 ~AboutDialog(void);
48 static const char *neroAacUrl, *disqueUrl;
50 public slots:
51 int exec();
52 void enableButtons(void);
53 void openURL(const QString &url);
54 void gotoLicenseTab(void);
55 void showAboutQt(void);
56 void moveDisque(void);
57 void tabChanged(int index, const bool silent = false);
58 void adjustSize(void);
59 void geometryUpdated(void);
61 protected:
62 virtual void showEvent(QShowEvent *e);
63 virtual void closeEvent(QCloseEvent *e);
64 bool eventFilter(QObject *obj, QEvent *event);
66 private:
67 Ui::AboutDialog *ui; //for Qt UIC
69 const bool m_firstStart;
70 SettingsModel *const m_settings;
71 QScopedPointer<QMap<QWidget*,bool>> m_initFlags;
72 int m_lastTab;
74 QScopedPointer<QLabel> m_disque;
75 QScopedPointer<QTimer> m_disqueTimer;
76 bool m_disqueFlags[2];
77 QPoint m_disquePos;
78 QRect m_disqueBound;
79 double m_discOpacity;
80 bool m_rotateNext;
81 QScopedPointer<QElapsedTimer> m_disqueDelay;
82 QScopedPointer<QPixmap> m_cartoon[4];
84 void initInformationTab(void);
85 void initContributorsTab(void);
86 void initSoftwareTab(void);
87 void initLicenseTab(void);
89 QString makeToolText(const QString &toolName, const QString &toolBin, const QString &toolVerFmt, const QString &toolLicense, const QString &toolWebsite, const QString &extraInfo = QString());