comparison layer/TimeValueLayer.cpp @ 455:747a58d45d56

* Fix incorrect starting extents in derived note & time-value layers (happening when top==bottom==0 and thus recalculated from model extents before model is complete)
author Chris Cannam
date Mon, 01 Dec 2008 16:45:17 +0000
parents 4a14499fb184
children 0990b95140e3
comparison
equal deleted inserted replaced
454:e2a40fdadd8c 455:747a58d45d56
265 TimeValueLayer::getDisplayExtents(float &min, float &max) const 265 TimeValueLayer::getDisplayExtents(float &min, float &max) const
266 { 266 {
267 if (!m_model || shouldAutoAlign()) return false; 267 if (!m_model || shouldAutoAlign()) return false;
268 268
269 if (m_scaleMinimum == m_scaleMaximum) { 269 if (m_scaleMinimum == m_scaleMaximum) {
270 m_scaleMinimum = m_model->getValueMinimum(); 270 min = m_model->getValueMinimum();
271 m_scaleMaximum = m_model->getValueMaximum(); 271 max = m_model->getValueMaximum();
272 return true;
272 } 273 }
273 274
274 min = m_scaleMinimum; 275 min = m_scaleMinimum;
275 max = m_scaleMaximum; 276 max = m_scaleMaximum;
276 277