From kde-commits Sat Jul 30 04:13:36 2005 From: Seb Ruiz Date: Sat, 30 Jul 2005 04:13:36 +0000 To: kde-commits Subject: extragear/multimedia/amarok/src Message-Id: <1122696816.479997.4882.nullmailer () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=112269684302959 SVN commit 440314 by seb: Dynamic - Dont disable items on app load if: * Resume on start is disabled, and hence m_currentTrack == 0 * Mark history is disabled M +7 -3 playlist.cpp --- trunk/extragear/multimedia/amarok/src/playlist.cpp #440313:440314 @@ -697,7 +697,10 @@ for( MyIterator it( this, MyIterator::All ) ; *it ; ++it ) { if( !entire ) - if ( *it == m_currentTrack ) break; + if( *it == m_currentTrack ) break; + + if( !enable ) + if( (*it)->isEnabled() ) break; //avoid repainting if we can. if( (*it)->isEnabled() != enable ) { @@ -725,7 +728,8 @@ if( QFile::exists( url.path() ) ) { //allows for history items to be re-enabled - if( isDynamic() ) m_stateSwitched = true; + if( isDynamic() && AmarokConfig::dynamicMarkHistory() ) + m_stateSwitched = true; ThreadWeaver::instance()->queueJob( new UrlLoader( url, 0 ) ); } } @@ -1964,7 +1968,7 @@ //re-disable history items if( isDynamic() ) { if( m_stateSwitched ) { - alterHistoryItems( false ); + alterHistoryItems( false, true ); // if resume on start is disabled, m_currentTrack == 0; m_stateSwitched = false; } }