From 1c250b334b32170f7f5958ff8c0b34c24833f3bd Mon Sep 17 00:00:00 2001 From: Jeff Mitchell Date: Fri, 26 Aug 2011 16:12:51 -0400 Subject: [PATCH] Handle checking queue in canGoNext so that we can use next() all the time instead of randomly skipping it and using loadNextTrack directly sometimes --- src/libtomahawk/audio/audioengine.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/libtomahawk/audio/audioengine.cpp b/src/libtomahawk/audio/audioengine.cpp index 79c1802b7..d14731106 100644 --- a/src/libtomahawk/audio/audioengine.cpp +++ b/src/libtomahawk/audio/audioengine.cpp @@ -137,7 +137,7 @@ AudioEngine::play() QVariant::fromValue< Tomahawk::InfoSystem::InfoCriteriaHash >( trackInfo ) ); } else - loadNextTrack(); + next(); } @@ -205,6 +205,10 @@ bool AudioEngine::canGoNext() { tDebug( LOGEXTRA ) << Q_FUNC_INFO; + + if ( m_queue && m_queue->trackCount() ) + return true; + if ( m_playlist.isNull() ) return false;