Sergio Martins
cdff9b3eaa
Some renaming
2019-07-30 16:59:29 +01:00
Sergio Martins
1e93160058
Remove some dead code from DockWidget
2019-07-30 16:57:26 +01:00
Sergio Martins
e53427a9fc
Only return HTCAPTION when clicking on the title bar
2019-07-30 16:48:29 +01:00
Sergio Martins
556df2b068
Only use the native event filter if aero snap is enabled
2019-07-30 16:21:23 +01:00
Sergio Martins
93a0377717
Don't allow to resize when clicking on the middle
...
It was using mCursorPos from previous invocations
2019-07-30 14:42:58 +01:00
Sergio Martins
9979696567
Fix being able to drag a FloatingWindow when dragging its body
...
We should only be able to drag via title bars, not widget
background.
This separates the concept of Draggable and Window, previously
they were mixed a bit. The draggable is something you drag,
usually a TitleBar, a Tab, or if using native window decorations
then FloatingWindow is also a draggable. Then, for each draggable
there's the actual window being dragged, that's always a FloatingWindow.
We should grab the mouse of the draggable.
2019-07-30 12:50:42 +01:00
Sergio Martins
80e98b32c3
Minor cleanup
2019-07-30 12:02:36 +01:00
Sergio Martins
6550939f0c
Fix typos
2019-07-30 11:00:54 +01:00
Sergio Martins
5854cd540a
Remove unused include
2019-07-30 10:26:00 +01:00
Sergio Martins
cdf0c88d45
Remove unneeded method
2019-07-30 10:14:53 +01:00
Sergio Martins
ed0cc44467
Simplify the drop/hover interfaces
...
Just pass FloatingWindow instead of Draggable. As we only drop
FloatingWindow.
2019-07-30 10:11:41 +01:00
Sergio Martins
42f2cc48b2
Simplify, remove unneeded code
...
Now that WindowBeingDragged deals only in terms of FloatingWindow.
2019-07-30 10:00:53 +01:00
Sergio Martins
316e3c8fd7
Simplify. DockWidget doesn't need to be a draggable
...
Floating dock widgets are FloatingWindow, and when docked
the draggable is the TitleBar, so this is dead code by now
2019-07-30 09:50:26 +01:00
Sergio Martins
f6a1d18d09
Add layout margins that were removed by mistake
2019-07-30 09:49:24 +01:00
Sergio Martins
d5faebb81c
Add support for aero-snap
2019-07-29 23:13:57 +01:00
Sergio Martins
1ed32283eb
Add a native resize handler for windows so we can have aero-snap
2019-07-29 22:21:15 +01:00
Sergio Martins
77a61aed23
Preserve Anchor position percentage after restore
2019-07-29 21:18:29 +01:00
Sergio Martins
7bcafb6ee3
Preserve anchor position percentage when restoring a maximized window
2019-07-29 20:31:51 +01:00
Sergio Martins
90cbd9731a
Fix anchors being out of bounds when consoming another multi splitter
...
dropping a multi splitter into another one wasn't honouring the bounds
of the donor's inner anchors
2019-07-29 18:54:09 +01:00
Sergio Martins
158c6157b5
Don't resize horizontal anchors when resizing window width
...
Similar for height
2019-07-29 18:53:29 +01:00
Sergio Martins
3c87d106ff
Actually remove the assert
2019-07-29 12:11:35 +01:00
Sergio Martins
a876249f13
Remove assert that can happen during a dumpDebug during restore
2019-07-29 12:07:06 +01:00
Sergio Martins
6fc9d48a9d
Don't warn if the current tab is -1
2019-07-29 11:33:47 +01:00
Sergio Martins
2b737ae6ad
Don't flicker when restoring
...
Only show the frame after it's parented
2019-07-29 11:01:06 +01:00
Sergio Martins
7400ae97de
Fix build
2019-07-28 21:13:31 +01:00
Sergio Martins
a69652a20a
DebugWindow: Add a way to repaint all windows
...
For debugging weird artifacts on MFC
2019-07-28 20:33:13 +01:00
Sergio Martins
d3256b5eb2
Fix linux build
2019-07-28 09:29:49 +01:00
Sergio Martins
13280dd01e
Also print Qt's version of the story
2019-07-27 20:16:24 +01:00
Sergio Martins
7f67349ab2
DebugWindow: Print native window rects
2019-07-27 20:00:14 +01:00
Sergio Martins
48e42b3247
Fix setContentSize() that was a no-op
...
Also, while restoring the layout don't resize the central widget
2019-07-27 19:09:27 +01:00
Sergio Martins
fd0b594331
Save the geometry of the actual top-level window
...
In case we have a main window embedded in another widget
2019-07-27 18:56:29 +01:00
Sergio Martins
1b249d68e9
Disable SeparatorWidget before the deleteLater
...
So we don't get an enterEvent
2019-07-27 11:35:12 +01:00
Sergio Martins
95f82cf8d7
Add assert
2019-07-27 11:26:03 +01:00
Sergio Martins
1f920a3aec
Add qDebug
2019-07-27 11:24:20 +01:00
Sergio Martins
73183a4fd5
Don't crash in a warning
2019-07-27 00:36:23 +01:00
Sergio Martins
a50683f400
Remove the Qt::WA_DontCreateNativeAncestors flag
...
IT doesn't fixes it completely
2019-07-27 00:06:47 +01:00
Sergio Martins
ab7f44f30a
DebugWindow: More debug helpers
2019-07-27 00:03:54 +01:00
Sergio Martins
5992114fc1
Allow to click on disabled widgets
2019-07-26 22:04:57 +01:00
Sergio Martins
6c18b25d00
DebugWindow: Add option to update and to print to png
2019-07-26 21:50:51 +01:00
Sergio Martins
c12a691433
Update Frame's icon and title when the dock widget's title/icon changes
2019-07-26 18:38:05 +01:00
Sergio Martins
f6304ee21e
refactor
2019-07-26 18:29:07 +01:00
Sergio Martins
a238b61ebf
Emit signal when icon changes
2019-07-26 18:22:42 +01:00
Sergio Martins
e55d4a97b7
also disable native parents in the dock widget ctor
...
since the client widget might already be parented to DockWidget,
so at least we stop it there
2019-07-26 18:10:32 +01:00
Sergio Martins
5ba23f3c5d
Add hasIcon property for gammaray
2019-07-26 18:05:57 +01:00
Sergio Martins
b196d6fad9
Add WA_DontCreateNativeAncestors
...
This is a good default to have, so we're shielded from the client
widget
2019-07-26 17:14:40 +01:00
Sergio Martins
a6270137ec
Debug++
2019-07-26 16:21:05 +01:00
Sergio Martins
10047fcd38
DebugWindow: Add a way to detach central widget for debug
2019-07-26 15:58:33 +01:00
Sergio Martins
61f6cdc650
DebugWindow :Print the geometry too
2019-07-26 15:55:43 +01:00
Sergio Martins
f624cf7bf4
Uncomment check which passes now
2019-07-26 14:40:01 +01:00
Sergio Martins
1a8a409f6f
Fix some out of bounds positionings
...
When calculating the cumulative min length some anchor thicknesses
were being accounted for because we had cleared the placeholders
2019-07-26 14:21:57 +01:00