Mercurial > hg > svgui
diff layer/WaveformLayer.cpp @ 915:f6d9f28f37cb osx-retina
Experiment with querying paint rect separately from view rect
author | Chris Cannam |
---|---|
date | Wed, 11 Mar 2015 15:35:20 +0000 |
parents | 4a578a360011 |
children | 94e4952a6774 |
line wrap: on
line diff
--- a/layer/WaveformLayer.cpp Wed Mar 11 13:54:01 2015 +0000 +++ b/layer/WaveformLayer.cpp Wed Mar 11 15:35:20 2015 +0000 @@ -494,8 +494,8 @@ mergingChannels, mixingChannels); if (channels == 0) return; - int w = v->width(); - int h = v->height(); + int w = v->getPaintWidth(); + int h = v->getPaintHeight(); bool ready = m_model->isReady(); QPainter *paint; @@ -559,7 +559,7 @@ y1 = rect.bottom(); if (x0 > 0) --x0; - if (x1 < v->width()) ++x1; + if (x1 < w) ++x1; // Our zoom level may differ from that at which the underlying // model has its blocks. @@ -939,7 +939,7 @@ if (m_aggressive) { - if (ready && rect == v->rect()) { + if (ready && rect == v->getPaintRect()) { m_cacheValid = true; m_cacheZoomLevel = zoomLevel; }