diff options
author | Sergio Martins <sergio.martins@kdab.com> | 2017-01-10 17:03:17 +0000 |
---|---|---|
committer | Sérgio Martins <sergio.martins@kdab.com> | 2017-02-01 10:15:07 +0000 |
commit | dd2a871eaefe8925c88a835bf298180044d4b0e9 (patch) | |
tree | f6e4941d60e975a4a278ddce1484c32b33ee83c7 /src/widgets/widgets/qmainwindowlayout_p.h | |
parent | fa8edcba0d4ebb5d9f66ff951e1870beb7b6a2db (diff) |
Clear dock indicator when not over a floating dock group window
The rubberband is shown depending if there's a current hovered dock widget,
but there were a few places that were not calling updateGapIndicator().
Additionally, the rubberband will also disappear if the currentHoveredFloat
is destroyed externally (would leave a ghost rubber band behind).
Task-number: QTBUG-58049
Change-Id: Iafdf234aa04b0ee280e51f8fa2fd212c86610cd1
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Diffstat (limited to 'src/widgets/widgets/qmainwindowlayout_p.h')
-rw-r--r-- | src/widgets/widgets/qmainwindowlayout_p.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/widgets/widgets/qmainwindowlayout_p.h b/src/widgets/widgets/qmainwindowlayout_p.h index 857a05eb8e..ed8da61bc3 100644 --- a/src/widgets/widgets/qmainwindowlayout_p.h +++ b/src/widgets/widgets/qmainwindowlayout_p.h @@ -306,13 +306,13 @@ public: #endif #ifndef QT_NO_DOCKWIDGET QPointer<QWidget> currentHoveredFloat; // set when dragging over a floating dock widget + void setCurrentHoveredFloat(QWidget *w); #endif void hover(QLayoutItem *widgetItem, const QPoint &mousePos); bool plug(QLayoutItem *widgetItem); QLayoutItem *unplug(QWidget *widget, bool group = false); void revert(QLayoutItem *widgetItem); - void updateGapIndicator(); void paintDropIndicator(QPainter *p, QWidget *widget, const QRegion &clip); void applyState(QMainWindowLayoutState &newState, bool animate = true); void restore(bool keepSavedState = false); @@ -320,6 +320,7 @@ public: void animationFinished(QWidget *widget); private Q_SLOTS: + void updateGapIndicator(); #ifndef QT_NO_DOCKWIDGET #ifndef QT_NO_TABBAR void tabChanged(); |