From 246723a5a2a76b083d605f561efc8be2f7dc44f0 Mon Sep 17 00:00:00 2001 From: David Sansome Date: Sun, 20 Mar 2011 12:39:49 +0000 Subject: [PATCH] Don't crash when dragging a file in the playlist by grabbing its rating. Fixes issue 1458 --- src/playlist/playlistview.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/playlist/playlistview.cpp b/src/playlist/playlistview.cpp index 429985312..2780cbc67 100644 --- a/src/playlist/playlistview.cpp +++ b/src/playlist/playlistview.cpp @@ -183,12 +183,16 @@ void PlaylistView::setModel(QAbstractItemModel *m) { if (model()) { disconnect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(InvalidateCachedCurrentPixmap())); + disconnect(model(), SIGNAL(layoutAboutToBeChanged()), + this, SLOT(RatingHoverOut())); } QTreeView::setModel(m); connect(model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(InvalidateCachedCurrentPixmap())); + connect(model(), SIGNAL(layoutAboutToBeChanged()), + this, SLOT(RatingHoverOut())); } void PlaylistView::LoadGeometry() {