added "About GoldenCheetah" dialog with build date and link to GPL

This commit is contained in:
Sean C. Rhea
2007-05-07 22:00:31 +00:00
parent 27bf8ae1ef
commit 866eec4eee
3 changed files with 23 additions and 0 deletions

View File

@@ -13,6 +13,7 @@ LIBS += -lm -lz
macx {
LIBS += -framework Carbon
}
QMAKE_CXXFLAGS = -DGC_BUILD_DATE="`date +'\"%a_%b_%d,_%Y\"'`"
# Input
HEADERS += \

View File

@@ -287,6 +287,9 @@ MainWindow::MainWindow(const QDir &home) :
rideMenu->addAction(tr("&Import from SRM..."), this,
SLOT(importSRM()), tr("Ctrl+I"));
QMenu *helpMenu = menuBar()->addMenu(tr("&Help"));
helpMenu->addAction(tr("&About GoldenCheetah"), this, SLOT(aboutDialog()));
if (last != NULL)
treeWidget->setCurrentItem(last);
}
@@ -656,3 +659,21 @@ MainWindow::pickerMoved(const QPoint &pos)
curve_to_point(minutes, cpintPlot->getAllCurve())));
}
void
MainWindow::aboutDialog()
{
QMessageBox::about(this, tr("About GoldenCheetah"), tr(
"<center>"
"<h2>GoldenCheetah</h2>"
"<i>Cycling Power Analysis Software for Linux and Mac OS X</i>"
"<p><i>Build date: "
"") + QString(GC_BUILD_DATE).replace("_", " ") + ("</i>"
"</center>"
"<p>GoldenCheetah is licensed under the "
"<a href=\"http://www.gnu.org/copyleft/gpl.html\">GNU General "
"Public License</a>. Source code can be obtained from "
"<a href=\"http://goldencheetah.org/\">"
"http://goldencheetah.org/</a>."
));
}

View File

@@ -56,6 +56,7 @@ class MainWindow : public QMainWindow
void setBinWidthFromLineEdit();
void tabChanged(int index);
void pickerMoved(const QPoint &);
void aboutDialog();
private: