Files
amnezia-client/client/ui/qml/Pages/PageGeneralSettings.qml
T

146 lines
3.1 KiB
QML
Raw Normal View History

2021-07-28 16:13:29 +07:00
import QtQuick 2.12
import QtQuick.Controls 2.12
2021-08-09 00:41:52 +07:00
import PageEnum 1.0
2021-07-28 16:13:29 +07:00
import "./"
2021-08-19 01:27:22 +03:00
import "../Controls"
import "../Config"
2021-07-28 16:13:29 +07:00
2021-09-14 00:39:07 +03:00
PageBase {
2021-07-28 16:13:29 +07:00
id: root
2021-09-14 00:39:07 +03:00
page: PageEnum.GeneralSettings
logic: GeneralSettingsLogic
2021-09-08 15:09:16 +03:00
BackButton {
2021-07-28 16:13:29 +07:00
id: back
}
2021-08-19 01:27:22 +03:00
Rectangle {
y: 40
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
y: 100
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
y: 160
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
y: 220
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
2021-07-28 16:13:29 +07:00
y: 280
2021-08-19 01:27:22 +03:00
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
2021-07-28 16:13:29 +07:00
y: 340
2021-08-19 01:27:22 +03:00
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
Rectangle {
2021-07-28 16:13:29 +07:00
y: 400
2021-08-19 01:27:22 +03:00
x: 20
width: parent.width - 40
2021-07-28 16:13:29 +07:00
height: 1
2021-08-19 01:27:22 +03:00
color: "#DDDDDD"
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
2021-07-28 16:13:29 +07:00
SettingButtonType {
x: 30
y: 355
width: 330
height: 30
icon.source: "qrc:/images/plus.png"
text: qsTr("Add server")
2021-08-09 00:41:52 +07:00
onClicked: {
UiLogic.goToPage(PageEnum.Start)
}
2021-07-28 16:13:29 +07:00
}
SettingButtonType {
x: 30
y: 55
width: 330
height: 30
icon.source: "qrc:/images/settings.png"
text: qsTr("App settings")
2021-08-09 00:41:52 +07:00
onClicked: {
UiLogic.goToPage(PageEnum.AppSettings)
}
2021-07-28 16:13:29 +07:00
}
SettingButtonType {
x: 30
y: 115
width: 330
height: 30
icon.source: "qrc:/images/settings.png"
text: qsTr("Network settings")
2021-08-09 00:41:52 +07:00
onClicked: {
UiLogic.goToPage(PageEnum.NetworkSettings)
}
2021-07-28 16:13:29 +07:00
}
SettingButtonType {
x: 30
y: 175
width: 330
height: 30
icon.source: "qrc:/images/server_settings.png"
text: qsTr("Server management")
2021-08-09 00:41:52 +07:00
onClicked: {
2021-09-03 20:17:13 +03:00
GeneralSettingsLogic.onPushButtonGeneralSettingsServerSettingsClicked()
2021-08-09 00:41:52 +07:00
}
2021-07-28 16:13:29 +07:00
}
SettingButtonType {
x: 30
y: 295
width: 330
height: 30
icon.source: "qrc:/images/server_settings.png"
text: qsTr("Servers")
2021-08-09 00:41:52 +07:00
onClicked: {
UiLogic.goToPage(PageEnum.ServersList)
}
2021-07-28 16:13:29 +07:00
}
SettingButtonType {
x: 30
y: 235
width: 330
height: 30
icon.source: "qrc:/images/share.png"
text: qsTr("Share connection")
2021-09-03 20:17:13 +03:00
enabled: GeneralSettingsLogic.pushButtonGeneralSettingsShareConnectionEnable
2021-08-09 00:41:52 +07:00
onClicked: {
2021-09-03 20:17:13 +03:00
GeneralSettingsLogic.onPushButtonGeneralSettingsShareConnectionClicked()
2021-08-09 00:41:52 +07:00
}
2021-07-28 16:13:29 +07:00
}
2021-08-19 01:27:22 +03:00
SettingButtonType {
x: 30
anchors.bottom: parent.bottom
anchors.bottomMargin: 20
width: 330
height: 30
icon.source: "qrc:/images/settings.png"
text: qsTr("Exit")
onClicked: {
Qt.quit()
}
}
2021-07-28 16:13:29 +07:00
}