Thanks Igor Costa de Faria for the sponsership [skip ci]

master
huxingyi 2020-07-13 07:49:34 +09:30
parent 39ec6a9aa7
commit b5a1d18a21
4 changed files with 31 additions and 0 deletions

2
SUPPORTERS Normal file
View File

@ -0,0 +1,2 @@
# Supporters ordered by first donation.
Igor Costa de Faria <https://github.com/IgorEagle>

View File

@ -35,6 +35,7 @@
<file>ACKNOWLEDGEMENTS.html</file> <file>ACKNOWLEDGEMENTS.html</file>
<file>AUTHORS</file> <file>AUTHORS</file>
<file>CONTRIBUTORS</file> <file>CONTRIBUTORS</file>
<file>SUPPORTERS</file>
<file>languages/dust3d_es_AR.qm</file> <file>languages/dust3d_es_AR.qm</file>
<file>languages/dust3d_it_IT.qm</file> <file>languages/dust3d_it_IT.qm</file>
</qresource> </qresource>

View File

@ -56,6 +56,7 @@ std::map<DocumentWindow *, QUuid> g_documentWindows;
QTextBrowser *g_acknowlegementsWidget = nullptr; QTextBrowser *g_acknowlegementsWidget = nullptr;
AboutWidget *g_aboutWidget = nullptr; AboutWidget *g_aboutWidget = nullptr;
QTextBrowser *g_contributorsWidget = nullptr; QTextBrowser *g_contributorsWidget = nullptr;
QTextBrowser *g_supportersWidget = nullptr;
UpdatesCheckWidget *g_updatesCheckWidget = nullptr; UpdatesCheckWidget *g_updatesCheckWidget = nullptr;
void outputMessage(QtMsgType type, const QMessageLogContext &context, const QString &msg) void outputMessage(QtMsgType type, const QMessageLogContext &context, const QString &msg)
@ -107,6 +108,21 @@ void DocumentWindow::showContributors()
g_contributorsWidget->raise(); g_contributorsWidget->raise();
} }
void DocumentWindow::showSupporters()
{
if (!g_supportersWidget) {
g_supportersWidget = new QTextBrowser;
g_supportersWidget->setWindowTitle(unifiedWindowTitle(tr("Supporters")));
g_supportersWidget->setMinimumSize(QSize(400, 300));
QFile supporters(":/SUPPORTERS");
supporters.open(QFile::ReadOnly | QFile::Text);
g_supportersWidget->setHtml("<h1>SUPPORTERS</h1><pre>" + supporters.readAll() + "</pre>");
}
g_supportersWidget->show();
g_supportersWidget->activateWindow();
g_supportersWidget->raise();
}
void DocumentWindow::showAbout() void DocumentWindow::showAbout()
{ {
if (!g_aboutWidget) { if (!g_aboutWidget) {
@ -903,6 +919,10 @@ DocumentWindow::DocumentWindow() :
connect(m_seeContributorsAction, &QAction::triggered, this, &DocumentWindow::seeContributors); connect(m_seeContributorsAction, &QAction::triggered, this, &DocumentWindow::seeContributors);
m_helpMenu->addAction(m_seeContributorsAction); m_helpMenu->addAction(m_seeContributorsAction);
m_seeSupportersAction = new QAction(tr("Supporters"), this);
connect(m_seeSupportersAction, &QAction::triggered, this, &DocumentWindow::seeSupporters);
m_helpMenu->addAction(m_seeSupportersAction);
m_seeAcknowlegementsAction = new QAction(tr("Acknowlegements"), this); m_seeAcknowlegementsAction = new QAction(tr("Acknowlegements"), this);
connect(m_seeAcknowlegementsAction, &QAction::triggered, this, &DocumentWindow::seeAcknowlegements); connect(m_seeAcknowlegementsAction, &QAction::triggered, this, &DocumentWindow::seeAcknowlegements);
m_helpMenu->addAction(m_seeAcknowlegementsAction); m_helpMenu->addAction(m_seeAcknowlegementsAction);
@ -1404,6 +1424,11 @@ void DocumentWindow::seeContributors()
DocumentWindow::showContributors(); DocumentWindow::showContributors();
} }
void DocumentWindow::seeSupporters()
{
DocumentWindow::showSupporters();
}
void DocumentWindow::initLockButton(QPushButton *button) void DocumentWindow::initLockButton(QPushButton *button)
{ {
QFont font; QFont font;

View File

@ -39,6 +39,7 @@ public:
static const std::map<DocumentWindow *, QUuid> &documentWindows(); static const std::map<DocumentWindow *, QUuid> &documentWindows();
static void showAcknowlegements(); static void showAcknowlegements();
static void showContributors(); static void showContributors();
static void showSupporters();
static void showAbout(); static void showAbout();
static size_t total(); static size_t total();
protected: protected:
@ -68,6 +69,7 @@ public slots:
void reportIssues(); void reportIssues();
void seeAcknowlegements(); void seeAcknowlegements();
void seeContributors(); void seeContributors();
void seeSupporters();
void seeReferenceGuide(); void seeReferenceGuide();
void documentChanged(); void documentChanged();
void updateRotationButtonState(); void updateRotationButtonState();
@ -203,6 +205,7 @@ private:
QAction *m_checkForUpdatesAction; QAction *m_checkForUpdatesAction;
QAction *m_reportIssuesAction; QAction *m_reportIssuesAction;
QAction *m_seeContributorsAction; QAction *m_seeContributorsAction;
QAction *m_seeSupportersAction;
QAction *m_seeAcknowlegementsAction; QAction *m_seeAcknowlegementsAction;
QAction *m_seeReferenceGuideAction; QAction *m_seeReferenceGuideAction;