From 5a921057356c767c42a2a322793178cc4e9293e4 Mon Sep 17 00:00:00 2001 From: Hyunjin Song Date: Thu, 4 Oct 2018 20:16:12 +0900 Subject: [PATCH] Don't always treat empty long patterns as BB patterns Due to the wrong condition for GUI handling, empty patterns longer than 1 bar was treated as BB patterns though they don't really look like. This commit drops the erroneous check and fixes related GUI issues. --- src/tracks/Pattern.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/tracks/Pattern.cpp b/src/tracks/Pattern.cpp index 01d51fbae..26cc1c9ec 100644 --- a/src/tracks/Pattern.cpp +++ b/src/tracks/Pattern.cpp @@ -713,8 +713,7 @@ void PatternView::mousePressEvent( QMouseEvent * _me ) { if( _me->button() == Qt::LeftButton && m_pat->m_patternType == Pattern::BeatPattern && - ( fixedTCOs() || pixelsPerTact() >= 96 || - m_pat->m_steps != MidiTime::stepsPerTact() ) && + ( fixedTCOs() || pixelsPerTact() >= 96 ) && _me->y() > height() - s_stepBtnOff->height() ) // when mouse button is pressed in beat/bassline -mode @@ -784,8 +783,7 @@ void PatternView::mouseDoubleClickEvent(QMouseEvent *_me) void PatternView::wheelEvent( QWheelEvent * _we ) { if( m_pat->m_patternType == Pattern::BeatPattern && - ( fixedTCOs() || pixelsPerTact() >= 96 || - m_pat->m_steps != MidiTime::stepsPerTact() ) && + ( fixedTCOs() || pixelsPerTact() >= 96 ) && _we->y() > height() - s_stepBtnOff->height() ) { // get the step number that was wheeled on and @@ -969,8 +967,7 @@ void PatternView::paintEvent( QPaintEvent * ) } // beat pattern paint event - else if( beatPattern && ( fixedTCOs() || ppt >= 96 - || m_pat->m_steps != MidiTime::stepsPerTact() ) ) + else if( beatPattern && ( fixedTCOs() || ppt >= 96 ) ) { QPixmap stepon0; QPixmap stepon200;