comparison view/AlignmentView.cpp @ 882:c0549bf12973 alignment_view

Fix misalignment in alignment view
author Chris Cannam
date Fri, 21 Nov 2014 14:50:27 +0000
parents 6a590241d8ad
children f2c63ec85901
comparison
equal deleted inserted replaced
881:6a590241d8ad 882:c0549bf12973
128 paint.fillRect(rect(), bg); 128 paint.fillRect(rect(), bg);
129 129
130 vector<int> keyFrames = getKeyFrames(); 130 vector<int> keyFrames = getKeyFrames();
131 131
132 foreach (int f, keyFrames) { 132 foreach (int f, keyFrames) {
133 int af = m_above->alignFromReference(f); 133 int ax = m_above->getXForFrame(f);
134 int ax = m_above->getXForFrame(af); 134 int rf = m_above->alignToReference(f);
135 int bf = m_below->alignFromReference(f); 135 int bf = m_below->alignFromReference(rf);
136 int bx = m_below->getXForFrame(bf); 136 int bx = m_below->getXForFrame(bf);
137 paint.drawLine(ax, 0, bx, height()); 137 paint.drawLine(ax, 0, bx, height());
138 } 138 }
139 139
140 paint.end(); 140 paint.end();