diff options
author | Thierry Bastian <thierry.bastian@nokia.com> | 2009-04-15 09:51:17 (GMT) |
---|---|---|
committer | Bradley T. Hughes <bradley.hughes@nokia.com> | 2009-04-15 16:14:17 (GMT) |
commit | 7cee817b4989ccff6f70b0fd9b87a250bb1ff9e3 (patch) | |
tree | e667d2a8d5a83a7756ca025d3a957d58ee185a68 /src/gui | |
parent | 8ec0109a5d5ce5e81a45ca8b294369a8a991f7f2 (diff) | |
download | Qt-7cee817b4989ccff6f70b0fd9b87a250bb1ff9e3.zip Qt-7cee817b4989ccff6f70b0fd9b87a250bb1ff9e3.tar.gz Qt-7cee817b4989ccff6f70b0fd9b87a250bb1ff9e3.tar.bz2 |
The submenu of a multicolumn menu have an incorrect position
The submenu would always appear to the side of the menu instead of its
right.
Task-number: 250673
Reviewed-by: ogoffart
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/widgets/qmenu.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/widgets/qmenu.cpp b/src/gui/widgets/qmenu.cpp index ed3e338..7396a9d 100644 --- a/src/gui/widgets/qmenu.cpp +++ b/src/gui/widgets/qmenu.cpp @@ -2889,8 +2889,8 @@ void QMenu::internalDelayedPopup() int subMenuOffset = style()->pixelMetric(QStyle::PM_SubMenuOverlap, 0, this); const QRect actionRect(d->actionRect(d->currentAction)); const QSize menuSize(d->activeMenu->sizeHint()); - const QPoint rightPos(mapToGlobal(QPoint(rect().right() + subMenuOffset + 1, actionRect.top()))); - const QPoint leftPos(mapToGlobal(QPoint(rect().left() - subMenuOffset - menuSize.width(), actionRect.top()))); + const QPoint rightPos(mapToGlobal(QPoint(actionRect.right() + subMenuOffset + 1, actionRect.top()))); + const QPoint leftPos(mapToGlobal(QPoint(actionRect.left() - subMenuOffset - menuSize.width(), actionRect.top()))); QPoint pos(rightPos); QMenu *caused = qobject_cast<QMenu*>(d->activeMenu->d_func()->causedPopup.widget); |