mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-08 23:26:40 +02:00
Set createplaylist playlist when creating createdynamicplaylist from json
This commit is contained in:
@@ -34,6 +34,8 @@ public:
|
|||||||
DynamicPlaylist* p = new DynamicPlaylist( source(), v.toMap().value( "type", QString() ).toString() );
|
DynamicPlaylist* p = new DynamicPlaylist( source(), v.toMap().value( "type", QString() ).toString() );
|
||||||
QJson::QObjectHelper::qvariant2qobject( v.toMap(), p );
|
QJson::QObjectHelper::qvariant2qobject( v.toMap(), p );
|
||||||
m_playlist = dynplaylist_ptr( p );
|
m_playlist = dynplaylist_ptr( p );
|
||||||
|
|
||||||
|
setPlaylist( m_playlist.staticCast<Tomahawk::Playlist>() );
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@@ -42,7 +42,8 @@ protected:
|
|||||||
void createPlaylist( DatabaseImpl* lib, bool dynamic = false );
|
void createPlaylist( DatabaseImpl* lib, bool dynamic = false );
|
||||||
|
|
||||||
bool report() { return m_report; }
|
bool report() { return m_report; }
|
||||||
|
void setPlaylist( const Tomahawk::playlist_ptr& playlist ) { m_playlist = playlist; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Tomahawk::playlist_ptr m_playlist;
|
Tomahawk::playlist_ptr m_playlist;
|
||||||
bool m_report; // call Playlist::reportCreated?
|
bool m_report; // call Playlist::reportCreated?
|
||||||
|
Reference in New Issue
Block a user