diff options
Diffstat (limited to 'tests/manual/quickdialogs/dialogs/MessageDialogPage.qml')
-rw-r--r-- | tests/manual/quickdialogs/dialogs/MessageDialogPage.qml | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/tests/manual/quickdialogs/dialogs/MessageDialogPage.qml b/tests/manual/quickdialogs/dialogs/MessageDialogPage.qml index 1fa2deef18..8ed211183b 100644 --- a/tests/manual/quickdialogs/dialogs/MessageDialogPage.qml +++ b/tests/manual/quickdialogs/dialogs/MessageDialogPage.qml @@ -1,5 +1,5 @@ // Copyright (C) 2021 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only import QtQuick import QtQuick.Controls @@ -20,6 +20,7 @@ ColumnLayout { title: qsTr("Dialog properties") Layout.fillWidth: true + Layout.fillHeight: false GridLayout { columns: 2 @@ -41,17 +42,20 @@ ColumnLayout { RadioButton { text: qsTr("Qt.NonModal") + Layout.fillWidth: false readonly property int modality: Qt.NonModal } RadioButton { text: qsTr("Qt.WindowModal") checked: true + Layout.fillWidth: false readonly property int modality: Qt.WindowModal } RadioButton { text: qsTr("Qt.ApplicationModal") + Layout.fillWidth: false readonly property int modality: Qt.ApplicationModal } @@ -65,6 +69,7 @@ ColumnLayout { text: messageBox.result === 1 ? qsTr("Accepted") : qsTr("Rejected") readOnly: true enabled: false + Layout.fillWidth: false } Label { @@ -73,6 +78,7 @@ ColumnLayout { TextField { id: titleTextField text: qsTr("Hello World") + Layout.fillWidth: false } } } @@ -81,6 +87,7 @@ ColumnLayout { title: qsTr("MessageBox properties") Layout.fillWidth: true + Layout.fillHeight: false ColumnLayout { RowLayout { @@ -90,6 +97,7 @@ ColumnLayout { TextField { id: textProperty text: qsTr("default text") + Layout.fillWidth: false } } RowLayout { @@ -99,6 +107,7 @@ ColumnLayout { TextField { id: informativeTextProperty text: qsTr("default informative text") + Layout.fillWidth: false } } @@ -116,6 +125,8 @@ ColumnLayout { border.width: 1 } Layout.maximumWidth: ApplicationWindow.window.width * 0.5 + Layout.fillWidth: false + Layout.fillHeight: false wrapMode: TextEdit.WordWrap text: qsTr("This text will be displayed in the 'detailed text' textArea, which the user must press a button to see.\n" + "If this is an empty string, the button will not be visible.") @@ -125,102 +136,119 @@ ColumnLayout { CheckBox { id: okCheckbox text: qsTr("Ok") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Ok : MessageDialog.NoButton } CheckBox { id: saveCheckbox text: qsTr("Save") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Save : MessageDialog.NoButton } CheckBox { id: saveAllCheckbox text: qsTr("Save All") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.SaveAll : MessageDialog.NoButton } CheckBox { id: openCheckbox text: qsTr("Open") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Open : MessageDialog.NoButton } CheckBox { id: yesCheckbox text: qsTr("Yes") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Yes : MessageDialog.NoButton } CheckBox { id: yesToAllCheckbox text: qsTr("Yes to all") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.YesToAll : MessageDialog.NoButton } CheckBox { id: noCheckbox text: qsTr("No") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.No : MessageDialog.NoButton } CheckBox { id: noToAllCheckbox text: qsTr("No to all") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.NoToAll : MessageDialog.NoButton } CheckBox { id: abortCheckbox text: qsTr("Abort") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Abort : MessageDialog.NoButton } CheckBox { id: retryCheckbox text: qsTr("Retry") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Retry : MessageDialog.NoButton } CheckBox { id: ignoreCheckbox text: qsTr("Ignore") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Ignore : MessageDialog.NoButton } CheckBox { id: closeCheckbox text: qsTr("Close") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Close : MessageDialog.NoButton } CheckBox { id: cancelCheckbox text: qsTr("Cancel") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Cancel : MessageDialog.NoButton } CheckBox { id: discardCheckbox text: qsTr("Discard") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Discard : MessageDialog.NoButton } CheckBox { id: helpCheckbox text: qsTr("Help") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Help : MessageDialog.NoButton } CheckBox { id: applyCheckbox text: qsTr("Apply") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Apply : MessageDialog.NoButton } CheckBox { id: resetCheckbox text: qsTr("Reset") + Layout.fillWidth: false readonly property int value: checked ? MessageDialog.Reset : MessageDialog.NoButton } |