Barlines now end at end of automation (#3387)

* Barlines now end at end of automation

* Removed redundant if check
This commit is contained in:
TheTravelingSpaceman
2017-03-01 01:08:09 +02:00
committed by Oskar Wallgren
parent 9124a367e4
commit 8283e3f456

View File

@@ -340,15 +340,12 @@ void AutomationPatternView::paintEvent( QPaintEvent * )
const int lineSize = 3;
p.setPen( c.darker( 300 ) );
for( tact_t t = 1; t < m_pat->timeMapLength().getTact(); ++t )
for( tact_t t = 1; t < width() - TCO_BORDER_WIDTH; ++t )
{
const int tx = x_base + static_cast<int>( ppt * t ) - 2;
if( tx < ( width() - TCO_BORDER_WIDTH * 2 ) )
{
p.drawLine( tx, TCO_BORDER_WIDTH, tx, TCO_BORDER_WIDTH + lineSize );
p.drawLine( tx, rect().bottom() - ( lineSize + TCO_BORDER_WIDTH ),
tx, rect().bottom() - TCO_BORDER_WIDTH );
}
p.drawLine( tx, TCO_BORDER_WIDTH, tx, TCO_BORDER_WIDTH + lineSize );
p.drawLine( tx, rect().bottom() - ( lineSize + TCO_BORDER_WIDTH ),
tx, rect().bottom() - TCO_BORDER_WIDTH );
}
// recording icon for when recording automation