diff --git a/client/translations/amneziavpn_ru.ts b/client/translations/amneziavpn_ru.ts index 0e1d65df..153c2569 100644 --- a/client/translations/amneziavpn_ru.ts +++ b/client/translations/amneziavpn_ru.ts @@ -130,7 +130,7 @@ ImportController - + Scanned %1 of %2. @@ -777,7 +777,7 @@ Already installed containers were found on the server. All installed containers - + Close application diff --git a/client/translations/amneziavpn_zh_CN.ts b/client/translations/amneziavpn_zh_CN.ts index 645d281f..4f566201 100644 --- a/client/translations/amneziavpn_zh_CN.ts +++ b/client/translations/amneziavpn_zh_CN.ts @@ -130,7 +130,7 @@ ImportController - + Scanned %1 of %2. 扫描 %1 of %2. @@ -811,7 +811,7 @@ Already installed containers were found on the server. All installed containers 关于 - + Close application diff --git a/client/ui/qml/Controls2/LabelWithButtonType.qml b/client/ui/qml/Controls2/LabelWithButtonType.qml index 6bc45a8c..8b85d591 100644 --- a/client/ui/qml/Controls2/LabelWithButtonType.qml +++ b/client/ui/qml/Controls2/LabelWithButtonType.qml @@ -20,7 +20,9 @@ Item { property bool isLeftImageHoverEnabled: true //todo separete this qml file to 3 property string textColor: "#d7d8db" + property string textDisabledColor: "#878B91" property string descriptionColor: "#878B91" + property string descriptionDisabledColor: "#494B50" property real textOpacity: 1.0 property string rightImageColor: "#d7d8db" @@ -71,7 +73,14 @@ Item { ListItemTitleType { text: root.text - color: root.descriptionOnTop ? root.descriptionColor : root.textColor + color: { + if (root.enabled) { + return root.descriptionOnTop ? root.descriptionColor : root.textColor + } else { + return root.descriptionOnTop ? root.descriptionDisabledColor : root.textDisabledColor + } + } + maximumLineCount: root.textMaximumLineCount elide: root.textElide @@ -96,7 +105,13 @@ Item { id: description text: root.descriptionText - color: root.descriptionOnTop ? root.textColor : root.descriptionColor + color: { + if (root.enabled) { + return root.descriptionOnTop ? root.textColor : root.descriptionColor + } else { + return root.descriptionOnTop ? root.textDisabledColor : root.descriptionDisabledColor + } + } opacity: root.textOpacity @@ -157,7 +172,7 @@ Item { MouseArea { anchors.fill: parent cursorShape: Qt.PointingHandCursor - hoverEnabled: true + hoverEnabled: root.enabled onEntered: { if (rightImageSource) { diff --git a/client/ui/qml/Pages2/PageSettingsConnection.qml b/client/ui/qml/Pages2/PageSettingsConnection.qml index 374e1ce4..76dbdff6 100644 --- a/client/ui/qml/Pages2/PageSettingsConnection.qml +++ b/client/ui/qml/Pages2/PageSettingsConnection.qml @@ -94,6 +94,8 @@ PageType { DividerType {} LabelWithButtonType { + visible: !GC.isMobile() + Layout.fillWidth: true text: qsTr("Split site tunneling") @@ -105,9 +107,13 @@ PageType { } } - DividerType {} + DividerType { + visible: !GC.isMobile() + } LabelWithButtonType { + visible: !GC.isMobile() + Layout.fillWidth: true text: qsTr("Separate application tunneling") @@ -118,7 +124,9 @@ PageType { } } - DividerType {} + DividerType { + visible: !GC.isMobile() + } } } } diff --git a/client/ui/qml/Pages2/PageSettingsSplitTunneling.qml b/client/ui/qml/Pages2/PageSettingsSplitTunneling.qml index b79d5d22..f90c6719 100644 --- a/client/ui/qml/Pages2/PageSettingsSplitTunneling.qml +++ b/client/ui/qml/Pages2/PageSettingsSplitTunneling.qml @@ -20,6 +20,10 @@ import "../Components" PageType { id: root + property bool pageEnabled: { + return !ConnectionController.isConnected + } + Connections { target: SitesController @@ -78,6 +82,8 @@ PageType { RowLayout { HeaderType { + enabled: root.pageEnabled + Layout.fillWidth: true Layout.leftMargin: 16 @@ -89,6 +95,8 @@ PageType { property int lastActiveRouteMode: routeMode.onlyForwardSites + enabled: root.pageEnabled + Layout.fillWidth: true Layout.rightMargin: 16 @@ -115,7 +123,7 @@ PageType { drawerHeight: 0.4375 - enabled: switcher.checked + enabled: switcher.checked && root.pageEnabled headerText: qsTr("Mode") @@ -155,9 +163,9 @@ PageType { FlickableType { anchors.top: header.bottom anchors.topMargin: 16 - contentHeight: col.implicitHeight + connectButton.implicitHeight + connectButton.anchors.bottomMargin + connectButton.anchors.topMargin + contentHeight: col.implicitHeight + addSiteButton.implicitHeight + addSiteButton.anchors.bottomMargin + addSiteButton.anchors.topMargin - enabled: switcher.checked + enabled: switcher.checked && root.pageEnabled Column { id: col @@ -221,8 +229,17 @@ PageType { } } + Rectangle { + anchors.fill: addSiteButton + anchors.bottomMargin: -24 + color: "#0E0E11" + opacity: 0.8 + } + RowLayout { - id: connectButton + id: addSiteButton + + enabled: root.pageEnabled anchors.bottom: parent.bottom anchors.left: parent.left