summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlessandro Portale <alessandro.portale@nokia.com>2009-10-01 09:42:37 (GMT)
committerAlessandro Portale <alessandro.portale@nokia.com>2009-10-01 09:59:55 (GMT)
commit997cb3006a8dfeea71132f9593c7421ca151f009 (patch)
treecd7d3da256951842e44784d06d046741827b8b70 /src
parente1496edf9e4dcec0f4e55fb320ec49dba9e548d5 (diff)
downloadQt-997cb3006a8dfeea71132f9593c7421ca151f009.zip
Qt-997cb3006a8dfeea71132f9593c7421ca151f009.tar.gz
Qt-997cb3006a8dfeea71132f9593c7421ca151f009.tar.bz2
Fix an issue that was uncovered by two tst_QAbstractItemView fails.
tst_QAbstractItemView::shiftArrowSelectionAfterScrolling() and tst_QAbstractItemView::shiftSelectionAfterRubberbandSelection() are two relatively new test cases that always failed when Qt was configured with QT_KEYPAD_NAVIGATION. And that even though we set the navigation mode to Qt::NavigationModeNone when running autotests for Symbian. Fix: in QAbstractItemViewPrivate::extendedSelectionCommand(), we make sure that even with keypad navigation enabled, the shift-arrow feature is available. Reviewed-by: Jani Hautakangas modified: src/gui/itemviews/qabstractitemview.cpp
Diffstat (limited to 'src')
-rw-r--r--src/gui/itemviews/qabstractitemview.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/itemviews/qabstractitemview.cpp b/src/gui/itemviews/qabstractitemview.cpp
index 303f45b..0fae959 100644
--- a/src/gui/itemviews/qabstractitemview.cpp
+++ b/src/gui/itemviews/qabstractitemview.cpp
@@ -3626,12 +3626,13 @@ QItemSelectionModel::SelectionFlags QAbstractItemViewPrivate::extendedSelectionC
case Qt::Key_PageUp:
case Qt::Key_PageDown:
case Qt::Key_Tab:
+ if (modifiers & Qt::ControlModifier
#ifdef QT_KEYPAD_NAVIGATION
- return QItemSelectionModel::NoUpdate;
-#else
- if (modifiers & Qt::ControlModifier)
- return QItemSelectionModel::NoUpdate;
+ // Preserve historical tab order navigation behavior
+ || QApplication::navigationMode() == Qt::NavigationModeKeypadTabOrder
#endif
+ )
+ return QItemSelectionModel::NoUpdate;
break;
case Qt::Key_Select:
return QItemSelectionModel::Toggle|selectionBehaviorFlags();