mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-06-23 02:00:20 +07:00
refact 2
This commit is contained in:
@@ -48,7 +48,7 @@ Item {
|
||||
y: 90
|
||||
width: 340
|
||||
height: 501
|
||||
model: UiLogic.serverListModel
|
||||
model: ServerListLogic.serverListModel
|
||||
spacing: 5
|
||||
delegate: Item {
|
||||
height: 60
|
||||
@@ -133,7 +133,7 @@ Item {
|
||||
icon.source: checked ? "qrc:/images/check.png"
|
||||
: "qrc:/images/uncheck.png"
|
||||
onClicked: {
|
||||
UiLogic.onServerListPushbuttonDefaultClicked(index)
|
||||
ServerListLogic.onServerListPushbuttonDefaultClicked(index)
|
||||
}
|
||||
checked: is_default
|
||||
enabled: !is_default
|
||||
@@ -146,7 +146,7 @@ Item {
|
||||
height: 24
|
||||
icon.source: "qrc:/images/settings.png"
|
||||
onClicked: {
|
||||
UiLogic.onServerListPushbuttonSettingsClicked(index)
|
||||
ServerListLogic.onServerListPushbuttonSettingsClicked(index)
|
||||
}
|
||||
OpacityAnimator {
|
||||
id: mouseEnterAni
|
||||
@@ -7,7 +7,7 @@ import "../Config"
|
||||
|
||||
Item {
|
||||
id: root
|
||||
enabled: UiLogic.pageServerSettingsEnabled
|
||||
enabled: ServerSettingsLogic.pageServerSettingsEnabled
|
||||
|
||||
ImageButtonType {
|
||||
id: back
|
||||
@@ -47,7 +47,7 @@ Item {
|
||||
height: 31
|
||||
font.pixelSize: 20
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
text: UiLogic.labelServerSettingsCurrentVpnProtocolText
|
||||
text: ServerSettingsLogic.labelServerSettingsCurrentVpnProtocolText
|
||||
}
|
||||
LabelType {
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
@@ -56,25 +56,25 @@ Item {
|
||||
height: 31
|
||||
font.pixelSize: 20
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
text: UiLogic.labelServerSettingsServerText
|
||||
text: ServerSettingsLogic.labelServerSettingsServerText
|
||||
}
|
||||
LabelType {
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
y: 530
|
||||
width: 301
|
||||
height: 41
|
||||
text: UiLogic.labelServerSettingsWaitInfoText
|
||||
visible: UiLogic.labelServerSettingsWaitInfoVisible
|
||||
text: ServerSettingsLogic.labelServerSettingsWaitInfoText
|
||||
visible: ServerSettingsLogic.labelServerSettingsWaitInfoVisible
|
||||
}
|
||||
TextFieldType {
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
y: 80
|
||||
width: 251
|
||||
height: 31
|
||||
text: UiLogic.lineEditServerSettingsDescriptionText
|
||||
text: UiLoServerSettingsLogicgic.lineEditServerSettingsDescriptionText
|
||||
onEditingFinished: {
|
||||
UiLogic.lineEditServerSettingsDescriptionText = text
|
||||
UiLogic.onLineEditServerSettingsDescriptionEditingFinished()
|
||||
ServerSettingsLogic.lineEditServerSettingsDescriptionText = text
|
||||
ServerSettingsLogic.onLineEditServerSettingsDescriptionEditingFinished()
|
||||
}
|
||||
}
|
||||
BlueButtonType {
|
||||
@@ -82,10 +82,10 @@ Item {
|
||||
y: 410
|
||||
width: 300
|
||||
height: 40
|
||||
text: UiLogic.pushButtonServerSettingsClearText
|
||||
visible: UiLogic.pushButtonServerSettingsClearVisible
|
||||
text: ServerSettingsLogic.pushButtonServerSettingsClearText
|
||||
visible: ServerSettingsLogic.pushButtonServerSettingsClearVisible
|
||||
onClicked: {
|
||||
UiLogic.onPushButtonClearServer()
|
||||
ServerSettingsLogic.onPushButtonServerSettingsClearServer()
|
||||
}
|
||||
}
|
||||
BlueButtonType {
|
||||
@@ -93,10 +93,10 @@ Item {
|
||||
y: 350
|
||||
width: 300
|
||||
height: 40
|
||||
text: UiLogic.pushButtonServerSettingsClearClientCacheText
|
||||
visible: UiLogic.pushButtonServerSettingsClearClientCacheVisible
|
||||
text: ServerSettingsLogic.pushButtonServerSettingsClearClientCacheText
|
||||
visible: ServerSettingsLogic.pushButtonServerSettingsClearClientCacheVisible
|
||||
onClicked: {
|
||||
UiLogic.onPushButtonServerSettingsClearClientCacheClicked()
|
||||
ServerSettingsLogic.onPushButtonServerSettingsClearClientCacheClicked()
|
||||
}
|
||||
}
|
||||
BlueButtonType {
|
||||
@@ -106,7 +106,7 @@ Item {
|
||||
height: 40
|
||||
text: qsTr("Forget this server")
|
||||
onClicked: {
|
||||
UiLogic.onPushButtonForgetServer()
|
||||
ServerSettingsLogic.onPushButtonServerSettingsForgetServer()
|
||||
}
|
||||
}
|
||||
BlueButtonType {
|
||||
@@ -116,7 +116,7 @@ Item {
|
||||
height: 40
|
||||
text: qsTr("VPN protocols")
|
||||
onClicked: {
|
||||
UiLogic.goToPage(PageEnum.ServerVpnProtocols)
|
||||
ServerSettingsLogic.goToPage(PageEnum.ServerVpnProtocols)
|
||||
}
|
||||
}
|
||||
BlueButtonType {
|
||||
@@ -125,9 +125,9 @@ Item {
|
||||
width: 300
|
||||
height: 40
|
||||
text: qsTr("Share Server (FULL ACCESS)")
|
||||
visible: UiLogic.pushButtonServerSettingsShareFullVisible
|
||||
visible: ServerSettingsLogic.pushButtonServerSettingsShareFullVisible
|
||||
onClicked: {
|
||||
UiLogic.onPushButtonServerSettingsShareFullClicked()
|
||||
ServerSettingsLogic.onPushButtonServerSettingsShareFullClicked()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user