Mercurial > hg > sonic-visualiser
comparison main/MainWindow.cpp @ 1610:3b8bd7e520c5
Note the release ID stuff to the debug log as well as in the about box
author | Chris Cannam |
---|---|
date | Fri, 24 Feb 2017 11:12:49 +0000 |
parents | 28d80ef79473 |
children | 3f6c18fcc075 |
comparison
equal
deleted
inserted
replaced
1609:751260ba5017 | 1610:3b8bd7e520c5 |
---|---|
173 m_unitConverter(new UnitConverter()), | 173 m_unitConverter(new UnitConverter()), |
174 m_keyReference(new KeyReference()), | 174 m_keyReference(new KeyReference()), |
175 m_templateWatcher(0) | 175 m_templateWatcher(0) |
176 { | 176 { |
177 Profiler profiler("MainWindow::MainWindow"); | 177 Profiler profiler("MainWindow::MainWindow"); |
178 | |
179 SVDEBUG << "MainWindow: " << getReleaseText() << endl; | |
178 | 180 |
179 setWindowTitle(QApplication::applicationName()); | 181 setWindowTitle(QApplication::applicationName()); |
180 | 182 |
181 UnitDatabase *udb = UnitDatabase::getInstance(); | 183 UnitDatabase *udb = UnitDatabase::getInstance(); |
182 udb->registerUnit("Hz"); | 184 udb->registerUnit("Hz"); |
4831 d->exec(); | 4833 d->exec(); |
4832 | 4834 |
4833 delete d; | 4835 delete d; |
4834 } | 4836 } |
4835 | 4837 |
4836 void | 4838 QString |
4837 MainWindow::about() | 4839 MainWindow::getReleaseText() const |
4838 { | 4840 { |
4839 bool debug = false; | 4841 bool debug = false; |
4840 QString version = "(unknown version)"; | 4842 QString version = "(unknown version)"; |
4841 | 4843 |
4842 #ifdef BUILD_DEBUG | 4844 #ifdef BUILD_DEBUG |
4852 #ifdef SVNREV | 4854 #ifdef SVNREV |
4853 version = tr("Unreleased : Revision %1").arg(SVNREV); | 4855 version = tr("Unreleased : Revision %1").arg(SVNREV); |
4854 #endif // SVNREV | 4856 #endif // SVNREV |
4855 #endif // SV_VERSION | 4857 #endif // SV_VERSION |
4856 | 4858 |
4857 QString aboutText; | 4859 return tr("%1 : %2 configuration, %3-bit build") |
4858 | |
4859 aboutText += tr("<h3>About Sonic Visualiser</h3>"); | |
4860 aboutText += tr("<p>Sonic Visualiser is a program for viewing and exploring audio data for semantic music analysis and annotation.<br><a href=\"http://www.sonicvisualiser.org/\">http://www.sonicvisualiser.org/</a></p>"); | |
4861 aboutText += tr("<p><small>%1 : %2 configuration, %3-bit build</small></p>") | |
4862 .arg(version) | 4860 .arg(version) |
4863 .arg(debug ? tr("Debug") : tr("Release")) | 4861 .arg(debug ? tr("Debug") : tr("Release")) |
4864 .arg(sizeof(void *) * 8); | 4862 .arg(sizeof(void *) * 8); |
4863 } | |
4864 | |
4865 void | |
4866 MainWindow::about() | |
4867 { | |
4868 QString aboutText; | |
4869 | |
4870 aboutText += tr("<h3>About Sonic Visualiser</h3>"); | |
4871 aboutText += tr("<p>Sonic Visualiser is a program for viewing and exploring audio data for semantic music analysis and annotation.<br><a href=\"http://www.sonicvisualiser.org/\">http://www.sonicvisualiser.org/</a></p>"); | |
4872 aboutText += QString("<p><small>%1</small></p>").arg(getReleaseText()); | |
4865 | 4873 |
4866 if (m_oscQueue && m_oscQueue->isOK()) { | 4874 if (m_oscQueue && m_oscQueue->isOK()) { |
4867 aboutText += tr("</small><p><small>The OSC URL for this instance is: \"%1\"").arg(m_oscQueue->getOSCURL()); | 4875 aboutText += tr("</small><p><small>The OSC URL for this instance is: \"%1\"").arg(m_oscQueue->getOSCURL()); |
4868 } | 4876 } |
4869 | 4877 |