2023-07-17 10:49:06 +02:00
|
|
|
import QtQuick
|
|
|
|
|
import QtQuick.Layouts
|
|
|
|
|
import QtQuick.Controls
|
2021-12-01 01:02:52 +01:00
|
|
|
|
2022-03-11 15:44:08 +01:00
|
|
|
import "wizard"
|
|
|
|
|
|
2021-12-01 01:02:52 +01:00
|
|
|
Wizard {
|
|
|
|
|
id: serverconnectwizard
|
|
|
|
|
|
2022-11-16 12:12:43 +01:00
|
|
|
wizardTitle: qsTr('Network configuration')
|
2021-12-01 01:02:52 +01:00
|
|
|
|
|
|
|
|
enter: null // disable transition
|
|
|
|
|
|
2022-10-04 19:47:29 +02:00
|
|
|
wiz: Daemon.serverConnectWizard
|
2023-02-24 22:11:20 +01:00
|
|
|
finishButtonText: qsTr('Next')
|
2022-10-04 19:47:29 +02:00
|
|
|
|
2021-12-01 01:02:52 +01:00
|
|
|
onAccepted: {
|
|
|
|
|
var proxy = wizard_data['proxy']
|
|
|
|
|
if (proxy && proxy['enabled'] == true) {
|
|
|
|
|
Network.proxy = proxy
|
|
|
|
|
} else {
|
|
|
|
|
Network.proxy = {'enabled': false}
|
|
|
|
|
}
|
|
|
|
|
Config.autoConnect = wizard_data['autoconnect']
|
|
|
|
|
if (!wizard_data['autoconnect']) {
|
|
|
|
|
Network.server = wizard_data['server']
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Component.onCompleted: {
|
2023-04-25 13:40:16 +02:00
|
|
|
var view = wiz.startWizard()
|
2022-10-04 19:47:29 +02:00
|
|
|
_loadNextComponent(view)
|
2021-12-01 01:02:52 +01:00
|
|
|
}
|
|
|
|
|
}
|