moved vpnConnection to separate thread

- added tabbar blocking when installing/removing containers
This commit is contained in:
vladimir.kuznetsov 2023-08-09 18:17:29 +05:00
parent e0d93eaa9f
commit 591d98d8b6
14 changed files with 128 additions and 95 deletions

View file

@ -14,6 +14,9 @@ import "../Config"
PageType {
id: root
Component.onCompleted: PageController.enableTabBar(false)
Component.onDestruction: PageController.enableTabBar(true)
SortFilterProxyModel {
id: proxyServersModel
sourceModel: ServersModel

View file

@ -299,6 +299,12 @@ PageType {
checked: additionalClientCommands !== ""
text: qsTr("Additional client configuration commands")
onCheckedChanged: {
if (!checked) {
additionalClientCommands = ""
}
}
}
TextAreaType {

View file

@ -21,7 +21,7 @@ PageType {
function onRestoreBackupFinished() {
PageController.showNotificationMessage(qsTr("Settings restored from backup file"))
goToStartPage()
//goToStartPage()
PageController.goToPageHome()
}
}

View file

@ -166,7 +166,7 @@ PageType {
questionDrawer.visible = false
goToPage(PageEnum.PageDeinstalling)
if (ServersModel.isDefaultServerCurrentlyProcessed() && ConnectionController.isConnected) {
ConnectionController.closeVpnConnection()
ConnectionController.closeConnection()
}
InstallController.removeAllContainers()
}

View file

@ -14,6 +14,9 @@ import "../Config"
PageType {
id: root
Component.onCompleted: PageController.enableTabBar(false)
Component.onDestruction: PageController.enableTabBar(true)
Connections {
target: InstallController

View file

@ -18,12 +18,12 @@ PageType {
function onGoToPageHome() {
tabBar.currentIndex = 0
tabBarStackView.goToTabBarPage(PageController.getPagePath(PageEnum.PageHome))
tabBarStackView.goToTabBarPage(PageEnum.PageHome)
}
function onGoToPageSettings() {
tabBar.currentIndex = 2
tabBarStackView.goToTabBarPage(PageController.getPagePath(PageEnum.PageSettings))
tabBarStackView.goToTabBarPage(PageEnum.PageSettings)
}
function onGoToPageViewConfig() {
@ -37,6 +37,10 @@ PageType {
tabBar.enabled = !visible
}
function onEnableTabBar(enabled) {
tabBar.enabled = enabled
}
function onClosePage() {
if (tabBarStackView.depth <= 1) {
return