diff --git a/resources/qml/device-verification/AwaitingVerificationConfirmation.qml b/resources/qml/device-verification/AwaitingVerificationConfirmation.qml deleted file mode 100644 index 5062a5dd78feb60e20af3271c51111ba0e1883bc..0000000000000000000000000000000000000000 --- a/resources/qml/device-verification/AwaitingVerificationConfirmation.qml +++ /dev/null @@ -1,53 +0,0 @@ -// SPDX-FileCopyrightText: 2021 Nheko Contributors -// SPDX-FileCopyrightText: 2022 Nheko Contributors -// -// SPDX-License-Identifier: GPL-3.0-or-later - -import "../ui" -import QtQuick 2.3 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.10 -import im.nheko 1.0 - -Pane { - property string title: qsTr("Awaiting Confirmation") - - ColumnLayout { - spacing: 16 - - Label { - id: content - - Layout.maximumWidth: 400 - Layout.fillHeight: true - Layout.fillWidth: true - wrapMode: Text.Wrap - text: qsTr("Waiting for other side to complete verification.") - color: Nheko.colors.text - verticalAlignment: Text.AlignVCenter - } - - Spinner { - Layout.alignment: Qt.AlignHCenter - foreground: Nheko.colors.mid - } - - RowLayout { - Button { - Layout.alignment: Qt.AlignLeft - text: qsTr("Cancel") - onClicked: { - flow.cancel(); - dialog.close(); - } - } - - Item { - Layout.fillWidth: true - } - - } - - } - -} diff --git a/resources/qml/device-verification/DeviceVerification.qml b/resources/qml/device-verification/DeviceVerification.qml index eea1756fbeecf6f1972cd9ea408794ee86afb269..c00a0bdbae95c304607a5baf3c9c8dffc348748d 100644 --- a/resources/qml/device-verification/DeviceVerification.qml +++ b/resources/qml/device-verification/DeviceVerification.qml @@ -14,10 +14,11 @@ ApplicationWindow { property var flow onClosing: VerificationManager.removeVerificationFlow(flow) - title: stack.currentItem.title + title: stack.currentItem.title_ modality: Qt.NonModal palette: Nheko.colors - height: stack.implicitHeight + color: Nheko.colors.window + minimumHeight: stack.implicitHeight width: stack.implicitWidth flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint Component.onCompleted: Nheko.reparent(dialog) @@ -25,6 +26,7 @@ ApplicationWindow { StackView { id: stack + anchors.fill: parent initialItem: newVerificationRequest implicitWidth: currentItem.implicitWidth implicitHeight: currentItem.implicitHeight diff --git a/resources/qml/device-verification/DigitVerification.qml b/resources/qml/device-verification/DigitVerification.qml index 5a2d416eaf0bbb8740004e64c952d7db77e8b328..3a8b0df561ddfcdef7b4c10ec72a5efea467d648 100644 --- a/resources/qml/device-verification/DigitVerification.qml +++ b/resources/qml/device-verification/DigitVerification.qml @@ -10,13 +10,16 @@ import im.nheko 1.0 Pane { property string title: qsTr("Verification Code") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Label { - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: qsTr("Please verify the following digits. You should see the same numbers on both sides. If they differ, please press 'They do not match!' to abort verification!") @@ -24,6 +27,7 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } RowLayout { Layout.alignment: Qt.AlignHCenter @@ -46,6 +50,7 @@ Pane { } } + Item { Layout.fillHeight: true; } RowLayout { Button { diff --git a/resources/qml/device-verification/EmojiVerification.qml b/resources/qml/device-verification/EmojiVerification.qml index ded163bd6d7e41fb608a0cc21cba7d52fde93db1..4c5bfb1ab961639499b57405c148f3348dbbe2e8 100644 --- a/resources/qml/device-verification/EmojiVerification.qml +++ b/resources/qml/device-verification/EmojiVerification.qml @@ -10,13 +10,16 @@ import im.nheko 1.0 Pane { property string title: qsTr("Verification Code") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Label { - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: qsTr("Please verify the following emoji. You should see the same emoji on both sides. If they differ, please press 'They do not match!' to abort verification!") @@ -24,6 +27,7 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } RowLayout { id: emojis @@ -391,6 +395,7 @@ Pane { } } + Item { Layout.fillHeight: true; } RowLayout { Button { diff --git a/resources/qml/device-verification/Failed.qml b/resources/qml/device-verification/Failed.qml index 83f4218aefd5363b7ad80d45198ffd668ff4d07c..d070b5a6565a9089813ec8996518664fa77188e1 100644 --- a/resources/qml/device-verification/Failed.qml +++ b/resources/qml/device-verification/Failed.qml @@ -10,15 +10,18 @@ import im.nheko 1.0 Pane { property string title: qsTr("Verification failed") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Text { id: content - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: { @@ -43,6 +46,8 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } + RowLayout { Item { Layout.fillWidth: true diff --git a/resources/qml/device-verification/NewVerificationRequest.qml b/resources/qml/device-verification/NewVerificationRequest.qml index 7facb7255fe0f5ae0362de111e4161c7836c6e49..b7ed9586c93cd2cc31b1f9b039eb08197db7f0b0 100644 --- a/resources/qml/device-verification/NewVerificationRequest.qml +++ b/resources/qml/device-verification/NewVerificationRequest.qml @@ -10,15 +10,18 @@ import im.nheko 1.0 Pane { property string title: flow.sender ? qsTr("Send Verification Request") : qsTr("Received Verification Request") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Label { // Self verification - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: { @@ -43,6 +46,8 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } + RowLayout { Button { Layout.alignment: Qt.AlignLeft diff --git a/resources/qml/device-verification/Success.qml b/resources/qml/device-verification/Success.qml index c74f0ea8b9e517eb4c565526c29c2824da56cda6..8d7c841944361e61a7ba4b299c479c1ff3a10ca9 100644 --- a/resources/qml/device-verification/Success.qml +++ b/resources/qml/device-verification/Success.qml @@ -10,15 +10,18 @@ import im.nheko 1.0 Pane { property string title: qsTr("Successful Verification") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Label { id: content - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: qsTr("Verification successful! Both sides verified their devices!") @@ -26,6 +29,8 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } + RowLayout { Item { Layout.fillWidth: true diff --git a/resources/qml/device-verification/Waiting.qml b/resources/qml/device-verification/Waiting.qml index 4584a2022b11240ab9999d73b4d9d3f6f2141cfd..e75a97ce1f4f4d30c69a28d29d7dd5cf901c1eed 100644 --- a/resources/qml/device-verification/Waiting.qml +++ b/resources/qml/device-verification/Waiting.qml @@ -11,15 +11,18 @@ import im.nheko 1.0 Pane { property string title: qsTr("Waiting for other party…") + background: Rectangle { + color: Nheko.colors.window + } ColumnLayout { + anchors.fill: parent spacing: 16 Label { id: content - Layout.maximumWidth: 400 - Layout.fillHeight: true + Layout.preferredWidth: 400 Layout.fillWidth: true wrapMode: Text.Wrap text: { @@ -36,10 +39,12 @@ Pane { verticalAlignment: Text.AlignVCenter } + Item { Layout.fillHeight: true; } Spinner { Layout.alignment: Qt.AlignHCenter foreground: Nheko.colors.mid } + Item { Layout.fillHeight: true; } RowLayout { Button {