diff options
author | Pierre Rossi <pierre.rossi@nokia.com> | 2011-01-10 17:46:19 (GMT) |
---|---|---|
committer | Qt Commercial Integration <QtCommercial@digia.com> | 2012-01-31 10:25:02 (GMT) |
commit | fd8df6ad5640cbdb4f4d24b8dcd72e14b063cc76 (patch) | |
tree | 73e3c49a3db8eb255509b8ada90e20e164afb54a /src/gui/widgets/qmenu_p.h | |
parent | 8b6cbe211675828ad2a53d109e85af2503ffe93c (diff) | |
download | Qt-fd8df6ad5640cbdb4f4d24b8dcd72e14b063cc76.zip Qt-fd8df6ad5640cbdb4f4d24b8dcd72e14b063cc76.tar.gz Qt-fd8df6ad5640cbdb4f4d24b8dcd72e14b063cc76.tar.bz2 |
Fix a bug with menu overflowing from a lower resolution second screen.
The menu needs to take into account the screen geometry of the screen
it's about to be shown on (not the last screen it was shown on) when
updating its actions rects
Task-number: QTBUG-2748
Reviewed-by: Thierry
Diffstat (limited to 'src/gui/widgets/qmenu_p.h')
-rw-r--r-- | src/gui/widgets/qmenu_p.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/widgets/qmenu_p.h b/src/gui/widgets/qmenu_p.h index 809555d..0e63799 100644 --- a/src/gui/widgets/qmenu_p.h +++ b/src/gui/widgets/qmenu_p.h @@ -194,10 +194,13 @@ public: mutable QVector<QRect> actionRects; mutable QHash<QAction *, QWidget *> widgetItems; void updateActionRects() const; + void updateActionRects(const QRect &screen) const; QRect popupGeometry(const QWidget *widget) const; QRect popupGeometry(int screen = -1) const; mutable uint ncols : 4; //4 bits is probably plenty uint collapsibleSeparators : 1; + QSize adjustMenuSizeForScreen(const QRect & screen); + int getLastVisibleAction() const; bool activationRecursionGuard; @@ -296,7 +299,6 @@ public: void updateLayoutDirection(); - //menu fading/scrolling effects bool doChildEffects; |