Mercurial > hg > sonic-visualiser
changeset 909:d0b89689f2b4
Update and merge
author | Chris Cannam |
---|---|
date | Thu, 26 Feb 2015 09:44:08 +0000 |
parents | 62198dde171e (current diff) fbd2534d17f8 (diff) |
children | c08df7de50f6 |
files | .hgsubstate |
diffstat | 3 files changed, 26 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/.hgsubstate Thu Feb 26 09:43:12 2015 +0000 +++ b/.hgsubstate Thu Feb 26 09:44:08 2015 +0000 @@ -1,5 +1,5 @@ d16f0fd6db6104d87882bc43788a3bb1b0f8c528 dataquay 879bdc878826bebec67130326f99397c430419b1 sv-dependency-builds 7b2dd0d4c366057ce25547a4015f3a76981abedc svapp -3a48b22fed4873d2edf1826f1c1fe1b5f77ed020 svcore +780959a4fe23619a2efdfaaa2414e9f3ec18045f svcore 78e041e45ff0ff3c103e0d794c6f66f391020aff svgui
--- a/main/PreferencesDialog.cpp Thu Feb 26 09:43:12 2015 +0000 +++ b/main/PreferencesDialog.cpp Thu Feb 26 09:44:08 2015 +0000 @@ -292,6 +292,14 @@ connect(ttMode, SIGNAL(currentIndexChanged(int)), this, SLOT(timeToTextModeChanged(int))); + QCheckBox *hms = new QCheckBox; + int showHMS = prefs->getPropertyRangeAndValue + ("Show Hours And Minutes", &min, &max, &deflt); + m_showHMS = (showHMS != 0); + hms->setCheckState(m_showHMS ? Qt::Checked : Qt::Unchecked); + connect(hms, SIGNAL(stateChanged(int)), + this, SLOT(showHMSChanged(int))); + // General tab QFrame *frame = new QFrame; @@ -342,6 +350,11 @@ row = 0; subgrid->addWidget(new QLabel(tr("%1:").arg(prefs->getPropertyLabel + ("Show Splash Screen"))), + row, 0); + subgrid->addWidget(showSplash, row++, 1, 1, 1); + + subgrid->addWidget(new QLabel(tr("%1:").arg(prefs->getPropertyLabel ("Property Box Layout"))), row, 0); subgrid->addWidget(propertyLayout, row++, 1, 1, 2); @@ -364,9 +377,9 @@ subgrid->addWidget(ttMode, row++, 1, 1, 2); subgrid->addWidget(new QLabel(tr("%1:").arg(prefs->getPropertyLabel - ("Show Splash Screen"))), + ("Show Hours And Minutes"))), row, 0); - subgrid->addWidget(showSplash, row++, 1, 1, 1); + subgrid->addWidget(hms, row++, 1, 1, 1); subgrid->setRowStretch(row, 10); @@ -609,6 +622,13 @@ } void +PreferencesDialog::showHMSChanged(int state) +{ + m_showHMS = (state == Qt::Checked); + m_applyButton->setEnabled(true); +} + +void PreferencesDialog::octaveSystemChanged(int system) { m_octaveSystem = system; @@ -647,6 +667,7 @@ prefs->setTemporaryDirectoryRoot(m_tempDirRoot); prefs->setBackgroundMode(Preferences::BackgroundMode(m_backgroundMode)); prefs->setTimeToTextMode(Preferences::TimeToTextMode(m_timeToTextMode)); + prefs->setShowHMS(m_showHMS); prefs->setViewFontSize(m_viewFontSize); prefs->setProperty("Octave Numbering System", m_octaveSystem);
--- a/main/PreferencesDialog.h Thu Feb 26 09:43:12 2015 +0000 +++ b/main/PreferencesDialog.h Thu Feb 26 09:44:08 2015 +0000 @@ -57,6 +57,7 @@ void tempDirRootChanged(QString root); void backgroundModeChanged(int mode); void timeToTextModeChanged(int mode); + void showHMSChanged(int state); void octaveSystemChanged(int system); void viewFontSizeChanged(int sz); void showSplashChanged(int state); @@ -97,6 +98,7 @@ QString m_tempDirRoot; int m_backgroundMode; int m_timeToTextMode; + bool m_showHMS; int m_octaveSystem; int m_viewFontSize; bool m_showSplash;