Mercurial > hg > svgui
changeset 438:76cd1c89eb06
* minor tidy
author | Chris Cannam |
---|---|
date | Fri, 24 Oct 2008 16:21:57 +0000 |
parents | 755243c67f59 |
children | 681542f0c8c5 |
files | layer/TimeValueLayer.cpp view/Pane.cpp widgets/Panner.cpp |
diffstat | 3 files changed, 9 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/layer/TimeValueLayer.cpp Fri Oct 24 14:52:40 2008 +0000 +++ b/layer/TimeValueLayer.cpp Fri Oct 24 16:21:57 2008 +0000 @@ -67,6 +67,9 @@ connectSignals(m_model); + m_scaleMinimum = 0; + m_scaleMaximum = 0; + // std::cerr << "TimeValueLayer::setModel(" << model << ")" << std::endl; emit modelReplaced(); @@ -292,7 +295,7 @@ m_scaleMinimum = min; m_scaleMaximum = max; - std::cerr << "TimeValueLayer::setDisplayExtents: min = " << min << ", max = " << max << std::endl; +// std::cerr << "TimeValueLayer::setDisplayExtents: min = " << min << ", max = " << max << std::endl; emit layerParametersChanged(); return true;
--- a/view/Pane.cpp Fri Oct 24 14:52:40 2008 +0000 +++ b/view/Pane.cpp Fri Oct 24 16:21:57 2008 +0000 @@ -2137,8 +2137,8 @@ float y1 = y0 + h; float newmax = vmin + ((1.0 - y0) * (vmax - vmin)); float newmin = vmin + ((1.0 - y1) * (vmax - vmin)); - std::cerr << "verticalPannerMoved: (" << x0 << "," << y0 << "," << w - << "," << h << ") -> (" << newmin << "," << newmax << ")" << std::endl; +// std::cerr << "verticalPannerMoved: (" << x0 << "," << y0 << "," << w +// << "," << h << ") -> (" << newmin << "," << newmax << ")" << std::endl; setTopLayerDisplayExtents(newmin, newmax); }
--- a/widgets/Panner.cpp Fri Oct 24 14:52:40 2008 +0000 +++ b/widgets/Panner.cpp Fri Oct 24 16:21:57 2008 +0000 @@ -156,15 +156,15 @@ paint.setPen(palette().dark().color()); paint.setBrush(bg); - paint.drawRect(0, 0, width(), height()); + paint.drawRect(0, 0, width()-1, height()-1); QColor hl(m_thumbColour); hl.setAlpha(m_thumbAlpha); paint.setBrush(hl); - int rw = lrintf(width() * m_rectWidth); - int rh = lrintf(height() * m_rectHeight); + int rw = lrintf((width() - 1) * m_rectWidth); + int rh = lrintf((height() - 1) * m_rectHeight); if (rw < 2) rw = 2; if (rh < 2) rh = 2;