Sergio Martins
753fe57b30
Add a failing test for bug #237
2021-10-11 00:25:10 +01:00
Sergio Martins
9587c1b1e3
Add a test for issue #245
...
I can't repro still. Will wait for more feedback from reporter.
2021-10-10 19:32:27 +01:00
Sergio Martins
33c5647e57
Don't create duplicate central frame with restoring
...
When using MainWindowOption_HasCentralFrame we have a persistent
central frame which is never destroyed. When restoring a layout
we shouldn't create it, as it exists already.
2021-09-20 12:26:45 +01:00
Waqar Ahmed
8307598d5d
tests: Fix tests, only repro in some distros
2021-09-11 12:17:50 +01:00
Sergio Martins
fafc0b7946
Fix "normal geometry" not being restored
...
When restoring a maximized window, calling QWidget::showNormal()
on it wouldn't set it's previous non-maximized size.
QWidget::normalGeometry() doesn't have a setter, so use private API.
2021-09-04 19:59:03 +01:00
Sergio Martins
3b9773f872
Add support for restoring minimized/maximized floating window state
2021-09-02 18:32:35 +01:00
Sergio Martins
a0c97e3388
Fix layout save restore when using MainWindowOption_HasCentralWidget
...
Those checks don't make sense anymore
2021-09-02 11:05:57 +01:00
Sergio Martins
d2a3968897
tests: Add tests for MainWindowOption_HasCentralWidget
2021-09-02 10:53:08 +01:00
Sergio Martins
34676f016f
qtquick: Blacklist a Qt6 test
...
Works fine manually.
Qt6 refactored input event handling, which broke our Tests::doubleClickOn(QWindow).
2021-07-15 23:50:06 +01:00
Allen Winter
22a709a39e
fix more misspellings
2021-07-15 10:14:04 -04:00
Sergio Martins
8800c02403
Fix persistent central frame becoming invisible
...
Wouldn't affect functionality but would have a different color.
Fixes #220
2021-07-13 08:19:05 +01:00
Sergio Martins
4b06706d61
Port away from deprecated QWidget::isTopLevel()
...
Fixes Qt6 warnings about it
2021-07-10 07:18:27 -07:00
Sergio Martins
a6e62ec74d
qtquick|tests: trying to stabilize a test in CI
...
Can't repro locally.
2021-07-10 13:44:15 +01:00
Sergio Martins
330f5aebdf
cmake: Add -Wundef
2021-07-09 22:26:01 +01:00
Sergio Martins
f9f270980d
tests: Fix flaky test
...
The center indicator isn't exactly at the center of the window,
so this would fail sometimes. This is a quick workaround.
Will all API to the dock indicator interface if this isn't enough.
2021-07-03 10:46:26 +01:00
Sergio Martins
d3d040adee
qtquick: Fix tab current widget being wrong when current is removed
...
When the current dock widget is removed we need to assign another
one. QTabBar does this automatically.
Fixes #215
2021-07-02 22:54:20 +01:00
Sergio Martins
362f2d5750
qtquick: Add a failing test for #215
2021-07-02 16:56:40 +01:00
Sergio Martins
701df72db6
Remove some ifdefs regarding 5.9
...
The one missing QT_VERSION_CHECK was even wrong and triggering
even with Qt 5.15.
2021-07-01 16:54:44 +01:00
Sergio Martins
18b49686f1
tests|qtquick: Remove the XFAIL, fixed by #211
2021-06-29 00:15:48 +01:00
Sergio Martins
2fe8117e80
tests: Add a QVERIFY
2021-06-28 23:46:58 +01:00
Sergio Martins
89623eb8b4
tests|qtquick: Add a test for weirdness reported in #211
...
Not the exact issue from #211 , but more tests will follow
2021-06-28 22:27:11 +01:00
Eism
0ab701bab6
qtquick: Fix detecting top level geometry
...
For QtQuick we want the QWindow geometry. For QtWidget it just works,
as the top level widget as the same geometry as the window, unlike
QQuickItem.
Fixes issue #199
2021-05-24 11:45:37 +01:00
Sergio Martins
1721415799
Fix more warnings at shutdown
2021-05-23 22:42:26 +01:00
Sergio Martins
675da6b2e2
qtquick: Fix test on linux
...
Querying drop indicator doesn't work if indicator window
isn't visible, so actually do a full drag.
For issue #199
2021-05-23 22:06:05 +01:00
Sergio Martins
517bfca259
Add a unit-test for issue #199
2021-05-23 12:20:20 +01:00
Sergio Martins
b981fc4b7d
qtquick: Fix tst_dockWindowWithTwoSideBySideFramesIntoCenter()
...
Moving windows around is async for QtQuick and needs a wait
2021-05-20 22:44:58 +01:00
Sergio Martins
4b2f268921
qtquick: fix tst_positionWhenShown on Windows
2021-05-20 22:44:26 +01:00
Sergio Martins
4e8a9ff8ed
tests: fix a flaky test on Windows
...
The drop area doesn't fill the floating window, so the
center was off and the drop didn't happen
Additionally, disabled AeroSnap, for debugging purposes, so we can
actually see the window moving, otherwise it doesn't move, since
we can't fake a native drag. It's just a visual bonus, doesn't
affect the correctness.
2021-05-20 18:28:23 +01:00
Sergio Martins
18c9963124
qtquick|tests: Fix tst_lastFloatingPositionIsRestored
...
We need to compare the position of the Window
2021-05-18 15:00:21 -07:00
Sergio Martins
2dbdb9f7eb
qtquick: Fix restoring QWindow's geometry
...
We need to resize the QWindow.
Fixes issue #196
2021-05-17 22:46:56 +01:00
Sergio Martins
70ecdaf54c
Add a failing test for issue #196
2021-05-17 21:12:59 +01:00
Sergio Martins
2836edd32d
qtquick: Add a test to see that main window position is restored
...
Will improve it with QtQuick corner cases
2021-05-10 23:04:37 +01:00
Sergio Martins
bbbce6f694
qtquick: Fix close() not hidding the widget
...
QtQuick will emit a "visibleChanged(true)" when setting nullptr,
which we need to inhibit so it behaves like QtWidgets.
2021-05-02 11:22:26 +01:00
Sergio Martins
ba0d515330
qtquick: Don't run tst_maxSizedFloatingWindow
...
We only support max-size constraints for QtWidgets, for now.
2021-05-02 00:19:47 +01:00
Sergio Martins
69154c0384
qtquick: Make setParent(nullptr) to hide the widget too
...
As done for QtWidgets.
Fixes a case where closing the dock widget wouldn't hide it.
As reported by Roman
2021-05-02 00:11:58 +01:00
Sergio Martins
affb48f44d
Fix restoring side-bar widget when it was deleted previously
...
We need to consult the user's widget factory, just as we do
for other cases where the dock widget is missing
2021-04-29 21:36:56 +01:00
Sergio Martins
6a8e00bfa2
tests: Test restoring with DeleteOnClose and sidebar widgets
...
sidebar dock widgets which were deleted should still call
the user's dock widget factory
To be done next
2021-04-29 18:06:41 +01:00
Sergio Martins
d289134b15
Add a unit-test for disabling RelativeFloatingWindowGeometry
...
Fixes #175
2021-04-28 21:27:47 +01:00
Sergio Martins
83c744041e
Merge branch '1.3'
2021-04-27 23:52:17 +01:00
Sergio Martins
c4d3ba71b2
Fix crash due to MainWindow not clearing m_overlayedDockWidget
...
When we close the overlayed widget we need to clear this variable
Added 1 real fix and a prophylactic check too.
2021-04-27 23:49:26 +01:00
Sergio Martins
9d7de9ea4d
Fix sizing of widgets that skip LayoutSaver's restore
...
LayoutWidget::onResize() was bailing out early, but the actual
restore hadn't even started
2021-04-23 19:39:07 +01:00
Sergio Martins
b330f902fd
tests: Move class into the header
...
File is getting too big
2021-04-23 18:03:49 +01:00
Sergio Martins
aa76dfba02
LayoutSaver: Support the user's factory func doing remapping
...
While restoring a layout, we expect all widgets to exist already,
but we allow the user to create them delayed, by providing
us a factory function.
What we're supporting in this commit is the ability of the user's
factory function returning a dock widget with an ID different
than the one that was requested. We then save that mapping so the
rest of the layout restore works with the new ID.
2021-04-23 14:55:01 +01:00
Sergio Martins
39deb9ee83
tests: Minor refactoring, reduce copy-paste
2021-04-20 23:02:07 +01:00
Sergio Martins
2266f4a75c
Fix FloatingWindow max size when there's tabbed dock widget
...
We don't support this case yet
2021-04-20 22:56:26 +01:00
Sergio Martins
06b680f603
Also update FloatingWindow's max size when children change constraints
...
A dock widget can change its max size later in life, so we need
to react to that
2021-04-20 22:52:08 +01:00
Sergio Martins
d65dfeceb0
Fix QtQuick developer build
2021-04-05 06:34:44 +01:00
Sergio Martins
19730ab6a4
Fix crash when using MainWindow::layoutEqually()
...
When distributing space we should honour the other widgets
min-size too, and not give too much
Since the layouting code is complex, this won't be backported to
1.3
2021-03-31 15:23:24 +01:00
Sergio Martins
44ae75110b
Added MainWindowBase::closeAllDockWidgets()
2021-03-31 10:51:20 +01:00
Sergio Martins
446560931b
MDI: Fix docked widget geometries not being remembered when floating
...
We shouldn't move the Frame directly. Instead, do it through the
layout, which will then remember the last docked geometry
2021-03-07 16:56:37 +00:00