mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-09 15:47:38 +02:00
* Prevented over-zealous assert in PlaylistModel.
This commit is contained in:
@@ -383,6 +383,9 @@ PlaylistModel::parsedDroppedTracks( QList< query_ptr > tracks )
|
|||||||
void
|
void
|
||||||
PlaylistModel::beginPlaylistChanges()
|
PlaylistModel::beginPlaylistChanges()
|
||||||
{
|
{
|
||||||
|
if ( m_playlist.isNull() || !m_playlist->author()->isLocal() )
|
||||||
|
return;
|
||||||
|
|
||||||
Q_ASSERT( !m_changesOngoing );
|
Q_ASSERT( !m_changesOngoing );
|
||||||
m_changesOngoing = true;
|
m_changesOngoing = true;
|
||||||
}
|
}
|
||||||
@@ -391,6 +394,9 @@ PlaylistModel::beginPlaylistChanges()
|
|||||||
void
|
void
|
||||||
PlaylistModel::endPlaylistChanges()
|
PlaylistModel::endPlaylistChanges()
|
||||||
{
|
{
|
||||||
|
if ( m_playlist.isNull() || !m_playlist->author()->isLocal() )
|
||||||
|
return;
|
||||||
|
|
||||||
if ( m_changesOngoing )
|
if ( m_changesOngoing )
|
||||||
{
|
{
|
||||||
m_changesOngoing = false;
|
m_changesOngoing = false;
|
||||||
@@ -401,9 +407,6 @@ PlaylistModel::endPlaylistChanges()
|
|||||||
Q_ASSERT( false );
|
Q_ASSERT( false );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( m_playlist.isNull() || !m_playlist->author()->isLocal() )
|
|
||||||
return;
|
|
||||||
|
|
||||||
QList<plentry_ptr> l = playlistEntries();
|
QList<plentry_ptr> l = playlistEntries();
|
||||||
QString newrev = uuid();
|
QString newrev = uuid();
|
||||||
m_waitForRevision << newrev;
|
m_waitForRevision << newrev;
|
||||||
|
Reference in New Issue
Block a user