Potential crash fix

The special event filter probably shouldn't eat the enter key if we are
in the editing state.
This commit is contained in:
dt
2010-08-03 14:15:02 +02:00
parent a40094c99f
commit 376369d4ce

View File

@@ -75,7 +75,8 @@ void NavigationTreeView::keyPressEvent(QKeyEvent *event)
if ((event->key() == Qt::Key_Return
|| event->key() == Qt::Key_Enter)
&& event->modifiers() == 0
&& currentIndex().isValid()) {
&& currentIndex().isValid()
&& state() != QAbstractItemView::EditingState) {
emit activated(currentIndex());
return;
}