1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-04-14 13:01:53 +02:00

* Don't leak memory when setting new avatar on a Source.

This commit is contained in:
Christian Muehlhaeuser 2011-05-12 15:53:31 +02:00
parent 853c0a0170
commit 04cbc78ff7
2 changed files with 4 additions and 3 deletions

View File

@ -1,7 +1,7 @@
Version 0.1.0:
* Fix issue where track resolving spinner never stopped if tracks were
removed from playlist while resolving.
* Fix issues with stations where multiple tracks could be added at once
* Fix issues with stations where multiple tracks could be added at once.
* Allow multiple accounts of the same type.
* Add new Google account type that is a thin wrapper around a Jabber plugin.
* Overhaul the settings dialog interface.

View File

@ -117,7 +117,8 @@ Source::friendlyName() const
void
Source::setAvatar( const QPixmap& avatar )
{
//HACK: we should really properly make sure that only the GUI thread ever accesses this function
//FIXME: use a proper pixmap store that's thread-safe
delete m_avatar;
m_avatar = new QPixmap( avatar );
}
@ -125,7 +126,7 @@ Source::setAvatar( const QPixmap& avatar )
QPixmap
Source::avatar() const
{
//HACK: we should really properly make sure that only the GUI thread ever accesses this function
//FIXME: use a proper pixmap store that's thread-safe
if ( m_avatar )
return QPixmap( *m_avatar );
else