From fcec8ddd0283152935bcd87d8f1b5862d07f1a62 Mon Sep 17 00:00:00 2001 From: Umcaruje Date: Wed, 9 Mar 2016 16:59:19 +0100 Subject: [PATCH] Fix BBtrack updating; Fix the Pattern tooltip --- src/gui/AutomationPatternView.cpp | 2 ++ src/tracks/Pattern.cpp | 21 ++++++++++++++++++--- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/src/gui/AutomationPatternView.cpp b/src/gui/AutomationPatternView.cpp index 0872260b764..71fd0d6a422 100644 --- a/src/gui/AutomationPatternView.cpp +++ b/src/gui/AutomationPatternView.cpp @@ -60,6 +60,8 @@ AutomationPatternView::AutomationPatternView( AutomationPattern * _pattern, if( s_pat_rec == NULL ) { s_pat_rec = new QPixmap( embed::getIconPixmap( "pat_rec" ) ); } + + update(); } diff --git a/src/tracks/Pattern.cpp b/src/tracks/Pattern.cpp index 532b7c418bd..1257a76d91c 100644 --- a/src/tracks/Pattern.cpp +++ b/src/tracks/Pattern.cpp @@ -701,9 +701,9 @@ PatternView::PatternView( Pattern* pattern, TrackView* parent ) : s_stepBtnOffLight = new QPixmap( embed::getIconPixmap( "step_btn_off_light" ) ); } + + update(); - ToolTip::add( this, - tr( "use mouse wheel to set velocity of a step" ) ); setStyle( QApplication::style() ); } @@ -722,7 +722,22 @@ PatternView::~PatternView() void PatternView::update() { - m_pat->changeLength( m_pat->length() ); + if( fixedTCOs() ) + { + m_pat->changeLength( m_pat->length() ); + } + + if ( m_pat->m_patternType == Pattern::BeatPattern ) + { + ToolTip::add( this, + tr( "use mouse wheel to set velocity of a step" ) ); + } + else + { + ToolTip::add( this, + tr( "double-click to open in Piano Roll" ) ); + } + TrackContentObjectView::update(); }