Mercurial > hg > sonic-visualiser
diff main/MainWindow.cpp @ 174:aaf806ce329a
* Fix #1757772 tempo, dynamic related plug-ins bug -- make auto-align
only auto-align if there is a unit involved
* Fix #1755366 text layer bug in retrieved session
* Fix input model selection in plugin parameter dialog (was being ignored)
* Use lighter background than the standard widget one for panes (assuming the
widget background is light but not white) -- similarly darker if dark
* Fix colour reference counting in loaded session in SingleColourLayer
* Reset overview pane colour when switching dark background on or off
author | Chris Cannam |
---|---|
date | Tue, 14 Aug 2007 13:58:53 +0000 |
parents | c1980ed39d2e |
children | 5bde373ad5ca |
line wrap: on
line diff
--- a/main/MainWindow.cpp Fri Aug 10 16:36:50 2007 +0000 +++ b/main/MainWindow.cpp Tue Aug 14 13:58:53 2007 +0000 @@ -213,7 +213,14 @@ m_panLayer->setChannelMode(WaveformLayer::MergeChannels); m_panLayer->setAggressiveCacheing(true); m_overview->addLayer(m_panLayer); - m_panLayer->setBaseColour(ColourDatabase::getInstance()->getColourIndex(Qt::darkGreen)); + + if (m_viewManager->getGlobalDarkBackground()) { + m_panLayer->setBaseColour + (ColourDatabase::getInstance()->getColourIndex(tr("Bright Green"))); + } else { + m_panLayer->setBaseColour + (ColourDatabase::getInstance()->getColourIndex(tr("Green"))); + } m_playSource = new AudioCallbackPlaySource(m_viewManager); @@ -3535,8 +3542,17 @@ MainWindow::toggleDarkBackground() { if (!m_viewManager) return; + m_viewManager->setGlobalDarkBackground (!m_viewManager->getGlobalDarkBackground()); + + if (m_viewManager->getGlobalDarkBackground()) { + m_panLayer->setBaseColour + (ColourDatabase::getInstance()->getColourIndex(tr("Bright Green"))); + } else { + m_panLayer->setBaseColour + (ColourDatabase::getInstance()->getColourIndex(tr("Green"))); + } } void