1
0
mirror of https://github.com/clementine-player/Clementine synced 2025-01-19 04:50:16 +01:00

Don't crash when dragging a file in the playlist by grabbing its rating. Fixes issue 1458

This commit is contained in:
David Sansome 2011-03-20 12:39:49 +00:00
parent 8921b31ffd
commit 246723a5a2

View File

@ -183,12 +183,16 @@ void PlaylistView::setModel(QAbstractItemModel *m) {
if (model()) { if (model()) {
disconnect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), disconnect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)),
this, SLOT(InvalidateCachedCurrentPixmap())); this, SLOT(InvalidateCachedCurrentPixmap()));
disconnect(model(), SIGNAL(layoutAboutToBeChanged()),
this, SLOT(RatingHoverOut()));
} }
QTreeView::setModel(m); QTreeView::setModel(m);
connect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), connect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)),
this, SLOT(InvalidateCachedCurrentPixmap())); this, SLOT(InvalidateCachedCurrentPixmap()));
connect(model(), SIGNAL(layoutAboutToBeChanged()),
this, SLOT(RatingHoverOut()));
} }
void PlaylistView::LoadGeometry() { void PlaylistView::LoadGeometry() {