From 75cb46690921733eeef2a6bb61b1400da14c940d Mon Sep 17 00:00:00 2001 From: Leo Franchi Date: Sun, 16 Oct 2011 21:44:49 -0400 Subject: [PATCH] die die flicker --- src/libtomahawk/widgets/siblingcrumbbutton.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/libtomahawk/widgets/siblingcrumbbutton.cpp b/src/libtomahawk/widgets/siblingcrumbbutton.cpp index f9fc1554c..0a9a36c87 100644 --- a/src/libtomahawk/widgets/siblingcrumbbutton.cpp +++ b/src/libtomahawk/widgets/siblingcrumbbutton.cpp @@ -130,6 +130,17 @@ void SiblingCrumbButton::fillCombo() list << sibling.data().toString(); } + if ( m_combo->count() && list.count() ) + { + // Check if it's the same, Don't change if it is, as it'll cause flickering + QStringList old; + for ( int i = 0; i < m_combo->count(); i++ ) + old << m_combo->itemText( i ); + + if ( list == old ) + return; + } + m_combo->clear(); m_combo->addItems(list); m_combo->setCurrentIndex( m_combo->findText(text()));