summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2010-06-30 10:15:49 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2010-06-30 10:15:49 (GMT)
commit8ea60a39a8c4661db505a6dc1342e524ec2e460c (patch)
treecc8824e9dd8178908918cd6a0e5ceb332f55168b /src/gui/widgets
parenta377ae6a629051b9c06b32a993ca98be43f8c5fa (diff)
downloadQt-8ea60a39a8c4661db505a6dc1342e524ec2e460c.zip
Qt-8ea60a39a8c4661db505a6dc1342e524ec2e460c.tar.gz
Qt-8ea60a39a8c4661db505a6dc1342e524ec2e460c.tar.bz2
Fixed a crash in menubar with invisible actions
That would happen because the loop to find the next action when navigating with the keyboard was not good enough. Task-number: QTBUG-11823
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/qmenubar.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/widgets/qmenubar.cpp b/src/gui/widgets/qmenubar.cpp
index aa4ffce..e8e80b7 100644
--- a/src/gui/widgets/qmenubar.cpp
+++ b/src/gui/widgets/qmenubar.cpp
@@ -768,7 +768,7 @@ QAction *QMenuBarPrivate::getNextAction(const int _start, const int increment) c
const int start = (_start == -1 && increment == -1) ? actions.count() : _start;
const int end = increment == -1 ? 0 : actions.count() - 1;
- for (int i = start; start != end;) {
+ for (int i = start; i != end;) {
i += increment;
QAction *current = actions.at(i);
if (!actionRects.at(i).isNull() && (allowActiveAndDisabled || current->isEnabled()))