2023-02-22 01:48:49 +03:00
|
|
|
// SPDX-FileCopyrightText: Nheko Contributors
|
2022-01-29 19:30:56 +03:00
|
|
|
//
|
|
|
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
|
2022-01-12 21:09:46 +03:00
|
|
|
import QtQuick 2.15
|
|
|
|
import QtQuick.Controls 2.15
|
|
|
|
import QtQuick.Layouts 1.2
|
|
|
|
import QtQuick.Window 2.15
|
|
|
|
import im.nheko 1.0
|
|
|
|
import "../components/"
|
2023-02-06 15:56:23 +03:00
|
|
|
import ".."
|
2022-01-12 21:09:46 +03:00
|
|
|
|
2024-05-15 01:33:03 +03:00
|
|
|
ScrollView {
|
|
|
|
contentWidth: availableWidth
|
|
|
|
ColumnLayout {
|
|
|
|
width: parent.width
|
2022-01-12 21:09:46 +03:00
|
|
|
|
2022-01-24 02:41:55 +03:00
|
|
|
Item {
|
2024-05-15 01:33:03 +03:00
|
|
|
Layout.fillHeight: true
|
2022-01-12 21:09:46 +03:00
|
|
|
}
|
2024-05-15 01:33:03 +03:00
|
|
|
|
|
|
|
Image {
|
2022-01-24 02:41:55 +03:00
|
|
|
Layout.alignment: Qt.AlignHCenter
|
2024-05-15 01:33:03 +03:00
|
|
|
source: "qrc:/logos/splash.png"
|
|
|
|
Layout.preferredHeight: 256
|
|
|
|
Layout.preferredWidth: 256
|
2022-01-24 02:41:55 +03:00
|
|
|
}
|
2024-05-15 01:33:03 +03:00
|
|
|
|
|
|
|
Label {
|
2022-01-24 02:41:55 +03:00
|
|
|
Layout.margins: Nheko.paddingLarge
|
2024-05-15 01:33:03 +03:00
|
|
|
Layout.bottomMargin: 0
|
2022-01-24 02:41:55 +03:00
|
|
|
Layout.alignment: Qt.AlignHCenter
|
2024-05-15 01:33:03 +03:00
|
|
|
Layout.fillWidth: true
|
|
|
|
text: qsTr("Welcome to nheko! The desktop client for the Matrix protocol.")
|
|
|
|
color: palette.text
|
|
|
|
font.pointSize: fontMetrics.font.pointSize * 2
|
|
|
|
wrapMode: Text.Wrap
|
|
|
|
horizontalAlignment: Text.AlignHCenter
|
2022-01-24 02:41:55 +03:00
|
|
|
}
|
2024-05-15 01:33:03 +03:00
|
|
|
Label {
|
|
|
|
Layout.margins: Nheko.paddingLarge
|
|
|
|
Layout.alignment: Qt.AlignHCenter
|
2022-01-24 02:41:55 +03:00
|
|
|
Layout.fillWidth: true
|
2024-05-15 01:33:03 +03:00
|
|
|
text: qsTr("Enjoy your stay!")
|
|
|
|
color: palette.text
|
|
|
|
font.pointSize: fontMetrics.font.pointSize * 1.5
|
|
|
|
wrapMode: Text.Wrap
|
|
|
|
horizontalAlignment: Text.AlignHCenter
|
2022-01-12 21:09:46 +03:00
|
|
|
}
|
2023-02-06 15:56:23 +03:00
|
|
|
|
2024-05-15 01:33:03 +03:00
|
|
|
RowLayout {
|
|
|
|
Item {
|
|
|
|
Layout.fillWidth: true
|
|
|
|
}
|
|
|
|
FlatButton {
|
|
|
|
Layout.margins: Nheko.paddingLarge
|
|
|
|
Layout.alignment: Qt.AlignHCenter
|
|
|
|
text: qsTr("REGISTER")
|
|
|
|
onClicked: {
|
|
|
|
mainWindow.push(registerPage);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
FlatButton {
|
|
|
|
Layout.margins: Nheko.paddingLarge
|
|
|
|
Layout.alignment: Qt.AlignHCenter
|
|
|
|
text: qsTr("LOGIN")
|
|
|
|
onClicked: {
|
|
|
|
mainWindow.push(loginPage);
|
|
|
|
}
|
|
|
|
}
|
2023-02-06 15:56:23 +03:00
|
|
|
|
2024-05-15 01:33:03 +03:00
|
|
|
Item {
|
|
|
|
Layout.fillWidth: true
|
|
|
|
}
|
2023-02-06 15:56:23 +03:00
|
|
|
|
|
|
|
}
|
|
|
|
|
2024-05-15 01:33:03 +03:00
|
|
|
RowLayout {
|
|
|
|
Layout.alignment: Qt.AlignHCenter
|
2023-02-06 15:56:23 +03:00
|
|
|
Layout.margins: Nheko.paddingLarge
|
2023-02-09 00:45:09 +03:00
|
|
|
|
2024-05-15 01:33:03 +03:00
|
|
|
ToggleButton {
|
|
|
|
Layout.margins: Nheko.paddingLarge
|
|
|
|
Layout.alignment: Qt.AlignRight
|
|
|
|
checked: Settings.reducedMotion
|
|
|
|
onCheckedChanged: Settings.reducedMotion = checked
|
|
|
|
}
|
|
|
|
|
|
|
|
Label {
|
|
|
|
Layout.alignment: Qt.AlignLeft
|
|
|
|
Layout.margins: Nheko.paddingLarge
|
|
|
|
text: qsTr("Reduce animations")
|
|
|
|
color: palette.text
|
|
|
|
|
|
|
|
HoverHandler {
|
|
|
|
id: hovered
|
|
|
|
}
|
|
|
|
ToolTip.visible: hovered.hovered
|
|
|
|
ToolTip.text: qsTr("Nheko uses animations in several places to make stuff pretty. This allows you to turn those off if they make you feel unwell.")
|
|
|
|
ToolTip.delay: Nheko.tooltipDelay
|
2023-02-09 00:45:09 +03:00
|
|
|
}
|
2023-02-06 15:56:23 +03:00
|
|
|
}
|
2024-05-15 01:33:03 +03:00
|
|
|
Item {
|
|
|
|
Layout.fillHeight: true
|
|
|
|
}
|
2022-01-12 21:09:46 +03:00
|
|
|
}
|
|
|
|
}
|