From 8488eac0704b27370a1ffb6b2d7b92afd1415f60 Mon Sep 17 00:00:00 2001 From: Leo Franchi Date: Sun, 20 Nov 2011 22:38:22 -0500 Subject: [PATCH] TWK-531: Show (-) on new item after deleting an item --- src/sourcetree/sourcedelegate.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/sourcetree/sourcedelegate.cpp b/src/sourcetree/sourcedelegate.cpp index 6561acb6d..f0f705436 100644 --- a/src/sourcetree/sourcedelegate.cpp +++ b/src/sourcetree/sourcedelegate.cpp @@ -431,8 +431,14 @@ SourceDelegate::editorEvent ( QEvent* event, QAbstractItemModel* model, const QS if ( r.contains( ev->pos() ) ) { if ( event->type() == QEvent::MouseButtonRelease ) + { gpi->removeFromList(); + // Send a new mouse event to the view, since if the mouse is now over another item's delete area we want it to show up + QMouseEvent* ev = new QMouseEvent( QEvent::MouseMove, m_parent->viewport()->mapFromGlobal( QCursor::pos() ), Qt::NoButton, Qt::NoButton, Qt::NoModifier ); + QApplication::postEvent( m_parent->viewport(), ev ); + } + return true; } }