mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-14 18:14:50 +02:00
* Don't try to set an invalid page.
This commit is contained in:
@@ -501,6 +501,9 @@ PlaylistManager::applyFilter()
|
||||
void
|
||||
PlaylistManager::setPage( ViewPage* page, bool trackHistory )
|
||||
{
|
||||
if ( !page )
|
||||
return;
|
||||
|
||||
unlinkPlaylist();
|
||||
|
||||
if ( !m_pageHistory.contains( page ) )
|
||||
@@ -797,8 +800,12 @@ void
|
||||
PlaylistManager::showCurrentTrack()
|
||||
{
|
||||
ViewPage* page = pageForInterface( AudioEngine::instance()->currentTrackPlaylist() );
|
||||
setPage( page );
|
||||
page->jumpToCurrentTrack();
|
||||
|
||||
if ( page )
|
||||
{
|
||||
setPage( page );
|
||||
page->jumpToCurrentTrack();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user