aboutsummaryrefslogtreecommitdiffstats
path: root/src/quickcontrols/universal/Dialog.qml
diff options
context:
space:
mode:
authorTor Arne Vestbø <[email protected]>2024-12-16 14:04:35 +0100
committerTor Arne Vestbø <[email protected]>2024-12-19 12:39:38 +0100
commit43083e644174ceea08802127cefcbcc6f8e0e485 (patch)
tree30ce17ab0123f5ae0c0237899f4fbd463855c426 /src/quickcontrols/universal/Dialog.qml
parent3cdece6d7e08a53774820af6708a16ad3075e9c6 (diff)
Compute implicitSize based on implicitContentSize in Popup and subclasses
Popup uses a Pane as its popup item, so now that Pane reflects its explicitly set contentWidth/Height through implicitContentWidth/Height we can use the same expression for implicit width/height as regular controls, which hooks us into the safe area binding loop detection as well. Pick-to: 6.9 Change-Id: I3709978dae0271d7daf44fc6988f09f03df15b1f Reviewed-by: Mitch Curtis <[email protected]>
Diffstat (limited to 'src/quickcontrols/universal/Dialog.qml')
-rw-r--r--src/quickcontrols/universal/Dialog.qml4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/quickcontrols/universal/Dialog.qml b/src/quickcontrols/universal/Dialog.qml
index 1d21b48574..9ab03e5fbe 100644
--- a/src/quickcontrols/universal/Dialog.qml
+++ b/src/quickcontrols/universal/Dialog.qml
@@ -9,11 +9,11 @@ T.Dialog {
id: control
implicitWidth: Math.max(implicitBackgroundWidth + leftInset + rightInset,
- contentWidth + leftPadding + rightPadding,
+ implicitContentWidth + leftPadding + rightPadding,
implicitHeaderWidth,
implicitFooterWidth)
implicitHeight: Math.max(implicitBackgroundHeight + topInset + bottomInset,
- contentHeight + topPadding + bottomPadding
+ implicitContentHeight + topPadding + bottomPadding
+ (implicitHeaderHeight > 0 ? implicitHeaderHeight + spacing : 0)
+ (implicitFooterHeight > 0 ? implicitFooterHeight + spacing : 0))