mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-12 00:54:20 +02:00
add some asserts and debug to help track down the crash
debug--
This commit is contained in:
@@ -65,6 +65,9 @@ DatabaseCommand_SetDynamicPlaylistRevision::postCommitHook()
|
||||
foreach( const QVariant& v, orderedguids() )
|
||||
orderedentriesguids << v.toString();
|
||||
|
||||
Q_ASSERT( !source().isNull() );
|
||||
Q_ASSERT( !source()->collection().isNull() );
|
||||
qDebug() << "Postcommitting this playlist:" << playlistguid() << source().isNull() << source().data();
|
||||
// private, but we are a friend. will recall itself in its own thread:
|
||||
dynplaylist_ptr playlist = source()->collection()->dynamicPlaylist( playlistguid() );
|
||||
|
||||
|
@@ -382,7 +382,7 @@ Playlist::setNewRevision( const QString& rev,
|
||||
}
|
||||
|
||||
|
||||
const source_ptr&
|
||||
source_ptr
|
||||
Playlist::author()
|
||||
{
|
||||
return m_source;
|
||||
|
@@ -113,7 +113,7 @@ public:
|
||||
|
||||
virtual void loadRevision( const QString& rev = "" );
|
||||
|
||||
const source_ptr& author();
|
||||
source_ptr author();
|
||||
const QString& currentrevision() { return m_currentrevision; }
|
||||
const QString& title() { return m_title; }
|
||||
const QString& info() { return m_info; }
|
||||
|
@@ -248,7 +248,11 @@ DynamicPlaylist::reportCreated( const Tomahawk::dynplaylist_ptr& self )
|
||||
{
|
||||
qDebug() << Q_FUNC_INFO;
|
||||
Q_ASSERT( self.data() == this );
|
||||
Q_ASSERT( !author().isNull() );
|
||||
Q_ASSERT( !author()->collection().isNull() );
|
||||
// will emit Collection::playlistCreated(...)
|
||||
qDebug() << "Creating dynplaylist belonging to:" << author().data() << author().isNull();
|
||||
qDebug() << "REPORTING DYNAMIC PLAYLIST CREATED:" << this << author()->friendlyName();
|
||||
author()->collection()->addDynamicPlaylist( self );
|
||||
}
|
||||
|
||||
|
@@ -208,7 +208,7 @@ void SourceTreeItem::onDynamicPlaylistLoaded( DynamicPlaylistRevision revision )
|
||||
// qDebug() << "found dynamic playlist:" << (*pl)->title() << type;
|
||||
if ( type == SourcesModel::DynamicPlaylistSource && ptr == qlonglong( pl->data() ) )
|
||||
{
|
||||
//qDebug() << "Found playlist!";
|
||||
//qDebug() << "Found dynamicplaylist!";
|
||||
pi->setEnabled( true );
|
||||
m_current_dynamic_revisions.insert( pl->data()->guid(), revision.revisionguid );
|
||||
}
|
||||
|
Reference in New Issue
Block a user