diff options
author | Paul Olav Tvete <paul.tvete@qt.io> | 2018-09-24 13:51:01 +0200 |
---|---|---|
committer | Paul Olav Tvete <paul.tvete@qt.io> | 2018-09-27 14:31:34 +0000 |
commit | d429146431693eb4e931bf91ccc255044eb49022 (patch) | |
tree | 8577ff3bbc8c72d88821367f6a1043224ad80bdc /src | |
parent | 720e243d88e352276cfbbe0b13fa4860fb020b29 (diff) |
Keep tiled subwindow order on resize
QMdiArea::tileSubWindows() will move the active window to the first
position, in order to be consistent with other MDI applications on
Windows (according to the original commit message). However, the same
function is also used for re-tiling on resize, so we must make sure
to not reorder in that case.
Fixes: QTBUG-51761
Change-Id: Ibf93a0bf7e663f983b9160364f812c84b5539171
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/widgets/widgets/qmdiarea.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/widgets/qmdiarea.cpp b/src/widgets/widgets/qmdiarea.cpp index 8639f57ea1..f32cd26478 100644 --- a/src/widgets/widgets/qmdiarea.cpp +++ b/src/widgets/widgets/qmdiarea.cpp @@ -954,7 +954,7 @@ void QMdiAreaPrivate::rearrange(Rearranger *rearranger) } } - if (active && rearranger->type() == Rearranger::RegularTiler) { + if (active && rearranger->type() == Rearranger::RegularTiler && !tileCalledFromResizeEvent) { // Move active window in front if necessary. That's the case if we // have any windows with staysOnTopHint set. int indexToActive = widgets.indexOf((QWidget *)active); |