# HG changeset patch # User Chris Cannam # Date 1597758576 -3600 # Node ID 36634b427d6108fef50497cdb14855e24c1b3158 # Parent f67e9e12e10180f3906f5675e5a5c04753f470bb Fix wrongly-written test which made the mapping alignments line up wrongly in some cases where adjacent panes were related (but, because of this test, the alignment view thought they were not) diff -r f67e9e12e101 -r 36634b427d61 view/AlignmentView.cpp --- a/view/AlignmentView.cpp Fri Aug 14 10:46:11 2020 +0100 +++ b/view/AlignmentView.cpp Tue Aug 18 14:49:36 2020 +0100 @@ -192,8 +192,14 @@ int w = width(); int h = height(); - if (m_leftmostAbove > 0) { - + if (m_leftmostAbove >= 0) { + +#ifdef DEBUG_ALIGNMENT_VIEW + SVCERR << "AlignmentView: m_leftmostAbove = " << m_leftmostAbove + << ", we have a relationship with the pane above us: showing " + << "mappings in relation to that" << endl; +#endif + for (const auto &km: m_fromAboveMap) { sv_frame_t af = km.first; @@ -213,7 +219,13 @@ } else if (m_reference != nullptr) { // the below has nothing in common with the above: show things // in common with the reference instead - + +#ifdef DEBUG_ALIGNMENT_VIEW + SVCERR << "AlignmentView: m_leftmostAbove = " << m_leftmostAbove + << ", we have no relationship with the pane above us: showing " + << "mappings in relation to the reference instead" << endl; +#endif + for (const auto &km: m_fromReferenceMap) { sv_frame_t af = km.first;