added icons for buttons in the drop-down window of connections sharing.
- corrections in texts
This commit is contained in:
parent
1092abe776
commit
66f9a82f31
13 changed files with 136 additions and 109 deletions
|
|
@ -8,18 +8,23 @@ QDebug operator<<(QDebug debug, const amnezia::DockerContainer &c)
|
||||||
return debug;
|
return debug;
|
||||||
}
|
}
|
||||||
|
|
||||||
amnezia::DockerContainer ContainerProps::containerFromString(const QString &container){
|
amnezia::DockerContainer ContainerProps::containerFromString(const QString &container)
|
||||||
|
{
|
||||||
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
||||||
for (int i = 0; i < metaEnum.keyCount(); ++i) {
|
for (int i = 0; i < metaEnum.keyCount(); ++i) {
|
||||||
DockerContainer c = static_cast<DockerContainer>(i);
|
DockerContainer c = static_cast<DockerContainer>(i);
|
||||||
if (container == containerToString(c)) return c;
|
if (container == containerToString(c))
|
||||||
|
return c;
|
||||||
}
|
}
|
||||||
return DockerContainer::None;
|
return DockerContainer::None;
|
||||||
}
|
}
|
||||||
|
|
||||||
QString ContainerProps::containerToString(amnezia::DockerContainer c){
|
QString ContainerProps::containerToString(amnezia::DockerContainer c)
|
||||||
if (c == DockerContainer::None) return "none";
|
{
|
||||||
if (c == DockerContainer::Cloak) return "amnezia-openvpn-cloak";
|
if (c == DockerContainer::None)
|
||||||
|
return "none";
|
||||||
|
if (c == DockerContainer::Cloak)
|
||||||
|
return "amnezia-openvpn-cloak";
|
||||||
|
|
||||||
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
||||||
QString containerKey = metaEnum.valueToKey(static_cast<int>(c));
|
QString containerKey = metaEnum.valueToKey(static_cast<int>(c));
|
||||||
|
|
@ -27,9 +32,12 @@ QString ContainerProps::containerToString(amnezia::DockerContainer c){
|
||||||
return "amnezia-" + containerKey.toLower();
|
return "amnezia-" + containerKey.toLower();
|
||||||
}
|
}
|
||||||
|
|
||||||
QString ContainerProps::containerTypeToString(amnezia::DockerContainer c){
|
QString ContainerProps::containerTypeToString(amnezia::DockerContainer c)
|
||||||
if (c == DockerContainer::None) return "none";
|
{
|
||||||
if (c == DockerContainer::Ipsec) return "ikev2";
|
if (c == DockerContainer::None)
|
||||||
|
return "none";
|
||||||
|
if (c == DockerContainer::Ipsec)
|
||||||
|
return "ikev2";
|
||||||
|
|
||||||
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
QMetaEnum metaEnum = QMetaEnum::fromType<DockerContainer>();
|
||||||
QString containerKey = metaEnum.valueToKey(static_cast<int>(c));
|
QString containerKey = metaEnum.valueToKey(static_cast<int>(c));
|
||||||
|
|
@ -40,29 +48,21 @@ QString ContainerProps::containerTypeToString(amnezia::DockerContainer c){
|
||||||
QVector<amnezia::Proto> ContainerProps::protocolsForContainer(amnezia::DockerContainer container)
|
QVector<amnezia::Proto> ContainerProps::protocolsForContainer(amnezia::DockerContainer container)
|
||||||
{
|
{
|
||||||
switch (container) {
|
switch (container) {
|
||||||
case DockerContainer::None:
|
case DockerContainer::None: return {};
|
||||||
return { };
|
|
||||||
|
|
||||||
case DockerContainer::OpenVpn:
|
case DockerContainer::OpenVpn: return { Proto::OpenVpn };
|
||||||
return { Proto::OpenVpn };
|
|
||||||
|
|
||||||
case DockerContainer::ShadowSocks:
|
case DockerContainer::ShadowSocks: return { Proto::OpenVpn, Proto::ShadowSocks };
|
||||||
return { Proto::OpenVpn, Proto::ShadowSocks };
|
|
||||||
|
|
||||||
case DockerContainer::Cloak:
|
case DockerContainer::Cloak: return { Proto::OpenVpn, Proto::ShadowSocks, Proto::Cloak };
|
||||||
return { Proto::OpenVpn, Proto::ShadowSocks, Proto::Cloak };
|
|
||||||
|
|
||||||
case DockerContainer::Ipsec:
|
case DockerContainer::Ipsec: return { Proto::Ikev2 /*, Protocol::L2tp */ };
|
||||||
return { Proto::Ikev2 /*, Protocol::L2tp */};
|
|
||||||
|
|
||||||
case DockerContainer::Dns:
|
case DockerContainer::Dns: return {};
|
||||||
return { };
|
|
||||||
|
|
||||||
case DockerContainer::Sftp:
|
case DockerContainer::Sftp: return { Proto::Sftp };
|
||||||
return { Proto::Sftp};
|
|
||||||
|
|
||||||
default:
|
default: return { defaultProtocol(container) };
|
||||||
return { defaultProtocol(container) };
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -79,51 +79,48 @@ QList<DockerContainer> ContainerProps::allContainers()
|
||||||
|
|
||||||
QMap<DockerContainer, QString> ContainerProps::containerHumanNames()
|
QMap<DockerContainer, QString> ContainerProps::containerHumanNames()
|
||||||
{
|
{
|
||||||
return {
|
return { { DockerContainer::None, "Not installed" },
|
||||||
{DockerContainer::None, "Not installed"},
|
{ DockerContainer::OpenVpn, "OpenVPN" },
|
||||||
{DockerContainer::OpenVpn, "OpenVPN"},
|
{ DockerContainer::ShadowSocks, "OpenVPN over ShadowSocks" },
|
||||||
{DockerContainer::ShadowSocks, "OpenVpn over ShadowSocks"},
|
{ DockerContainer::Cloak, "OpenVPN over Cloak" },
|
||||||
{DockerContainer::Cloak, "OpenVpn over Cloak"},
|
{ DockerContainer::WireGuard, "WireGuard" },
|
||||||
{DockerContainer::WireGuard, "WireGuard"},
|
{ DockerContainer::Ipsec, QObject::tr("IPsec") },
|
||||||
{DockerContainer::Ipsec, QObject::tr("IPsec")},
|
|
||||||
|
|
||||||
{DockerContainer::TorWebSite, QObject::tr("Web site in Tor network")},
|
{ DockerContainer::TorWebSite, QObject::tr("Web site in Tor network") },
|
||||||
{DockerContainer::Dns, QObject::tr("DNS Service")},
|
{ DockerContainer::Dns, QObject::tr("Amnezia DNS") },
|
||||||
//{DockerContainer::FileShare, QObject::tr("SMB file sharing service")},
|
//{DockerContainer::FileShare, QObject::tr("SMB file sharing service")},
|
||||||
{DockerContainer::Sftp, QObject::tr("Sftp file sharing service")}
|
{ DockerContainer::Sftp, QObject::tr("Sftp file sharing service") } };
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QMap<DockerContainer, QString> ContainerProps::containerDescriptions()
|
QMap<DockerContainer, QString> ContainerProps::containerDescriptions()
|
||||||
{
|
{
|
||||||
return {
|
return { { DockerContainer::OpenVpn, QObject::tr("OpenVPN container") },
|
||||||
{DockerContainer::OpenVpn, QObject::tr("OpenVPN container")},
|
{ DockerContainer::ShadowSocks, QObject::tr("Container with OpenVpn and ShadowSocks") },
|
||||||
{DockerContainer::ShadowSocks, QObject::tr("Container with OpenVpn and ShadowSocks")},
|
{ DockerContainer::Cloak,
|
||||||
{DockerContainer::Cloak, QObject::tr("Container with OpenVpn and ShadowSocks protocols "
|
QObject::tr("Container with OpenVpn and ShadowSocks protocols "
|
||||||
"configured with traffic masking by Cloak plugin")},
|
"configured with traffic masking by Cloak plugin") },
|
||||||
{DockerContainer::WireGuard, QObject::tr("WireGuard container")},
|
{ DockerContainer::WireGuard, QObject::tr("WireGuard container") },
|
||||||
{DockerContainer::Ipsec, QObject::tr("IPsec container")},
|
{ DockerContainer::Ipsec, QObject::tr("IPsec container") },
|
||||||
|
|
||||||
{DockerContainer::TorWebSite, QObject::tr("Web site in Tor network")},
|
{ DockerContainer::TorWebSite, QObject::tr("Web site in Tor network") },
|
||||||
{DockerContainer::Dns, QObject::tr("DNS Service")},
|
{ DockerContainer::Dns, QObject::tr("DNS Service") },
|
||||||
//{DockerContainer::FileShare, QObject::tr("SMB file sharing service - is Window file sharing protocol")},
|
//{DockerContainer::FileShare, QObject::tr("SMB file sharing service - is Window file sharing protocol")},
|
||||||
{DockerContainer::Sftp, QObject::tr("Sftp file sharing service - is secure FTP service")}
|
{ DockerContainer::Sftp, QObject::tr("Sftp file sharing service - is secure FTP service") } };
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
amnezia::ServiceType ContainerProps::containerService(DockerContainer c)
|
amnezia::ServiceType ContainerProps::containerService(DockerContainer c)
|
||||||
{
|
{
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::None : return ServiceType::None;
|
case DockerContainer::None: return ServiceType::None;
|
||||||
case DockerContainer::OpenVpn : return ServiceType::Vpn;
|
case DockerContainer::OpenVpn: return ServiceType::Vpn;
|
||||||
case DockerContainer::Cloak : return ServiceType::Vpn;
|
case DockerContainer::Cloak: return ServiceType::Vpn;
|
||||||
case DockerContainer::ShadowSocks : return ServiceType::Vpn;
|
case DockerContainer::ShadowSocks: return ServiceType::Vpn;
|
||||||
case DockerContainer::WireGuard : return ServiceType::Vpn;
|
case DockerContainer::WireGuard: return ServiceType::Vpn;
|
||||||
case DockerContainer::Ipsec : return ServiceType::Vpn;
|
case DockerContainer::Ipsec: return ServiceType::Vpn;
|
||||||
case DockerContainer::TorWebSite : return ServiceType::Other;
|
case DockerContainer::TorWebSite: return ServiceType::Other;
|
||||||
case DockerContainer::Dns : return ServiceType::Other;
|
case DockerContainer::Dns: return ServiceType::Other;
|
||||||
//case DockerContainer::FileShare : return ServiceType::Other;
|
// case DockerContainer::FileShare : return ServiceType::Other;
|
||||||
case DockerContainer::Sftp : return ServiceType::Other;
|
case DockerContainer::Sftp: return ServiceType::Other;
|
||||||
default: return ServiceType::Other;
|
default: return ServiceType::Other;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -131,17 +128,17 @@ amnezia::ServiceType ContainerProps::containerService(DockerContainer c)
|
||||||
Proto ContainerProps::defaultProtocol(DockerContainer c)
|
Proto ContainerProps::defaultProtocol(DockerContainer c)
|
||||||
{
|
{
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::None : return Proto::Any;
|
case DockerContainer::None: return Proto::Any;
|
||||||
case DockerContainer::OpenVpn : return Proto::OpenVpn;
|
case DockerContainer::OpenVpn: return Proto::OpenVpn;
|
||||||
case DockerContainer::Cloak : return Proto::Cloak;
|
case DockerContainer::Cloak: return Proto::Cloak;
|
||||||
case DockerContainer::ShadowSocks : return Proto::ShadowSocks;
|
case DockerContainer::ShadowSocks: return Proto::ShadowSocks;
|
||||||
case DockerContainer::WireGuard : return Proto::WireGuard;
|
case DockerContainer::WireGuard: return Proto::WireGuard;
|
||||||
case DockerContainer::Ipsec : return Proto::Ikev2;
|
case DockerContainer::Ipsec: return Proto::Ikev2;
|
||||||
|
|
||||||
case DockerContainer::TorWebSite : return Proto::TorWebSite;
|
case DockerContainer::TorWebSite: return Proto::TorWebSite;
|
||||||
case DockerContainer::Dns : return Proto::Dns;
|
case DockerContainer::Dns: return Proto::Dns;
|
||||||
//case DockerContainer::FileShare : return Protocol::FileShare;
|
// case DockerContainer::FileShare : return Protocol::FileShare;
|
||||||
case DockerContainer::Sftp : return Proto::Sftp;
|
case DockerContainer::Sftp: return Proto::Sftp;
|
||||||
default: return Proto::Any;
|
default: return Proto::Any;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -151,22 +148,23 @@ bool ContainerProps::isSupportedByCurrentPlatform(DockerContainer c)
|
||||||
#ifdef Q_OS_WINDOWS
|
#ifdef Q_OS_WINDOWS
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
#elif defined (Q_OS_IOS)
|
#elif defined(Q_OS_IOS)
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::WireGuard: return true;
|
case DockerContainer::WireGuard: return true;
|
||||||
case DockerContainer::OpenVpn: return true;
|
case DockerContainer::OpenVpn: return true;
|
||||||
case DockerContainer::Cloak: return true;
|
case DockerContainer::Cloak:
|
||||||
// case DockerContainer::ShadowSocks: return true;
|
return true;
|
||||||
|
// case DockerContainer::ShadowSocks: return true;
|
||||||
default: return false;
|
default: return false;
|
||||||
}
|
}
|
||||||
#elif defined (Q_OS_MAC)
|
#elif defined(Q_OS_MAC)
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::WireGuard: return true;
|
case DockerContainer::WireGuard: return true;
|
||||||
case DockerContainer::Ipsec: return false;
|
case DockerContainer::Ipsec: return false;
|
||||||
default: return true;
|
default: return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined (Q_OS_ANDROID)
|
#elif defined(Q_OS_ANDROID)
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::WireGuard: return true;
|
case DockerContainer::WireGuard: return true;
|
||||||
case DockerContainer::OpenVpn: return true;
|
case DockerContainer::OpenVpn: return true;
|
||||||
|
|
@ -175,7 +173,7 @@ bool ContainerProps::isSupportedByCurrentPlatform(DockerContainer c)
|
||||||
default: return false;
|
default: return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined (Q_OS_LINUX)
|
#elif defined(Q_OS_LINUX)
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::WireGuard: return true;
|
case DockerContainer::WireGuard: return true;
|
||||||
case DockerContainer::Ipsec: return false;
|
case DockerContainer::Ipsec: return false;
|
||||||
|
|
@ -183,14 +181,14 @@ bool ContainerProps::isSupportedByCurrentPlatform(DockerContainer c)
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
return false;
|
return false;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
QStringList ContainerProps::fixedPortsForContainer(DockerContainer c)
|
QStringList ContainerProps::fixedPortsForContainer(DockerContainer c)
|
||||||
{
|
{
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case DockerContainer::Ipsec : return QStringList{"500", "4500"};
|
case DockerContainer::Ipsec: return QStringList { "500", "4500" };
|
||||||
default: return {};
|
default: return {};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -198,9 +196,9 @@ QStringList ContainerProps::fixedPortsForContainer(DockerContainer c)
|
||||||
bool ContainerProps::isEasySetupContainer(DockerContainer container)
|
bool ContainerProps::isEasySetupContainer(DockerContainer container)
|
||||||
{
|
{
|
||||||
switch (container) {
|
switch (container) {
|
||||||
case DockerContainer::OpenVpn : return true;
|
case DockerContainer::OpenVpn: return true;
|
||||||
case DockerContainer::Cloak : return true;
|
case DockerContainer::Cloak: return true;
|
||||||
case DockerContainer::ShadowSocks : return true;
|
case DockerContainer::ShadowSocks: return true;
|
||||||
default: return false;
|
default: return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -208,9 +206,9 @@ bool ContainerProps::isEasySetupContainer(DockerContainer container)
|
||||||
QString ContainerProps::easySetupHeader(DockerContainer container)
|
QString ContainerProps::easySetupHeader(DockerContainer container)
|
||||||
{
|
{
|
||||||
switch (container) {
|
switch (container) {
|
||||||
case DockerContainer::OpenVpn : return tr("Low");
|
case DockerContainer::OpenVpn: return tr("Low");
|
||||||
case DockerContainer::Cloak : return tr("High");
|
case DockerContainer::Cloak: return tr("High");
|
||||||
case DockerContainer::ShadowSocks : return tr("Medium");
|
case DockerContainer::ShadowSocks: return tr("Medium");
|
||||||
default: return "";
|
default: return "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -218,9 +216,9 @@ QString ContainerProps::easySetupHeader(DockerContainer container)
|
||||||
QString ContainerProps::easySetupDescription(DockerContainer container)
|
QString ContainerProps::easySetupDescription(DockerContainer container)
|
||||||
{
|
{
|
||||||
switch (container) {
|
switch (container) {
|
||||||
case DockerContainer::OpenVpn : return tr("Many foreign websites and VPN providers are blocked");
|
case DockerContainer::OpenVpn: return tr("I just want to increase the level of privacy");
|
||||||
case DockerContainer::Cloak : return tr("Some foreign sites are blocked, but VPN providers are not blocked");
|
case DockerContainer::Cloak: return tr("Some foreign sites are blocked, but VPN providers are not blocked");
|
||||||
case DockerContainer::ShadowSocks : return tr("I just want to increase the level of privacy");
|
case DockerContainer::ShadowSocks: return tr("Many foreign websites and VPN providers are blocked");
|
||||||
default: return "";
|
default: return "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -55,6 +55,7 @@ DrawerType {
|
||||||
Layout.topMargin: 16
|
Layout.topMargin: 16
|
||||||
|
|
||||||
text: qsTr("Share")
|
text: qsTr("Share")
|
||||||
|
imageSource: "qrc:/images/controls/share-2.svg"
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
ExportController.saveFile()
|
ExportController.saveFile()
|
||||||
|
|
@ -73,6 +74,7 @@ DrawerType {
|
||||||
borderWidth: 1
|
borderWidth: 1
|
||||||
|
|
||||||
text: qsTr("Copy")
|
text: qsTr("Copy")
|
||||||
|
imageSource: "qrc:/images/controls/copy.svg"
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
configText.selectAll()
|
configText.selectAll()
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
|
import QtQuick.Layouts
|
||||||
|
import Qt5Compat.GraphicalEffects
|
||||||
|
|
||||||
import "TextTypes"
|
import "TextTypes"
|
||||||
|
|
||||||
|
|
@ -16,6 +18,8 @@ Button {
|
||||||
property string borderColor: "#D7D8DB"
|
property string borderColor: "#D7D8DB"
|
||||||
property int borderWidth: 0
|
property int borderWidth: 0
|
||||||
|
|
||||||
|
property string imageSource
|
||||||
|
|
||||||
implicitHeight: 56
|
implicitHeight: 56
|
||||||
|
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
@ -48,11 +52,30 @@ Button {
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
}
|
}
|
||||||
|
|
||||||
contentItem: ButtonTextType {
|
contentItem: Item {
|
||||||
anchors.fill: background
|
anchors.fill: background
|
||||||
|
RowLayout {
|
||||||
|
anchors.centerIn: parent
|
||||||
|
|
||||||
|
Image {
|
||||||
|
source: root.imageSource
|
||||||
|
visible: root.imageSource === "" ? false : true
|
||||||
|
|
||||||
|
layer {
|
||||||
|
enabled: true
|
||||||
|
effect: ColorOverlay {
|
||||||
|
color: textColor
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ButtonTextType {
|
||||||
color: textColor
|
color: textColor
|
||||||
text: root.text
|
text: root.text
|
||||||
horizontalAlignment: Text.AlignHCenter
|
|
||||||
|
horizontalAlignment: Text.AlignLeft
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -155,7 +155,7 @@ PageType {
|
||||||
|
|
||||||
text: root.defaultContainerName
|
text: root.defaultContainerName
|
||||||
textColor: "#0E0E11"
|
textColor: "#0E0E11"
|
||||||
headerText: qsTr("Connection protocol")
|
headerText: qsTr("VPN protocol")
|
||||||
headerBackButtonImage: "qrc:/images/controls/arrow-left.svg"
|
headerBackButtonImage: "qrc:/images/controls/arrow-left.svg"
|
||||||
|
|
||||||
rootButtonClickedFunction: function() {
|
rootButtonClickedFunction: function() {
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@ PageType {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: 32
|
Layout.topMargin: 32
|
||||||
|
|
||||||
headerText: qsTr("Masquerading as traffic from")
|
headerText: qsTr("Disguised as traffic from")
|
||||||
textFieldText: site
|
textFieldText: site
|
||||||
|
|
||||||
textField.onEditingFinished: {
|
textField.onEditingFinished: {
|
||||||
|
|
@ -161,7 +161,7 @@ PageType {
|
||||||
Layout.topMargin: 24
|
Layout.topMargin: 24
|
||||||
Layout.bottomMargin: 24
|
Layout.bottomMargin: 24
|
||||||
|
|
||||||
text: qsTr("Save and Restart Amnesia")
|
text: qsTr("Save and Restart Amnezia")
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
forceActiveFocus()
|
forceActiveFocus()
|
||||||
|
|
|
||||||
|
|
@ -445,7 +445,7 @@ PageType {
|
||||||
Layout.topMargin: 24
|
Layout.topMargin: 24
|
||||||
Layout.bottomMargin: 24
|
Layout.bottomMargin: 24
|
||||||
|
|
||||||
text: qsTr("Save and Restart Amnesia")
|
text: qsTr("Save and Restart Amnezia")
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
forceActiveFocus()
|
forceActiveFocus()
|
||||||
|
|
|
||||||
|
|
@ -147,7 +147,7 @@ PageType {
|
||||||
Layout.topMargin: 24
|
Layout.topMargin: 24
|
||||||
Layout.bottomMargin: 24
|
Layout.bottomMargin: 24
|
||||||
|
|
||||||
text: qsTr("Save and Restart Amnesia")
|
text: qsTr("Save and Restart Amnezia")
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
forceActiveFocus()
|
forceActiveFocus()
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ PageType {
|
||||||
Layout.leftMargin: 16
|
Layout.leftMargin: 16
|
||||||
Layout.rightMargin: 16
|
Layout.rightMargin: 16
|
||||||
|
|
||||||
text: qsTr("Use AmnesiaDNS if installed on the server")
|
text: qsTr("Use AmneziaDNS if installed on the server")
|
||||||
descriptionText: qsTr("Internal IP address 172.29.172.254")
|
descriptionText: qsTr("Internal IP address 172.29.172.254")
|
||||||
|
|
||||||
checked: SettingsController.isAmneziaDnsEnabled()
|
checked: SettingsController.isAmneziaDnsEnabled()
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,7 @@ PageType {
|
||||||
visible: content.isServerWithWriteAccess
|
visible: content.isServerWithWriteAccess
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
text: qsTr("Check the server for previously installed Amnesia services")
|
text: qsTr("Check the server for previously installed Amnezia services")
|
||||||
descriptionText: qsTr("Add them to the application if they were not displayed")
|
descriptionText: qsTr("Add them to the application if they were not displayed")
|
||||||
|
|
||||||
clickedFunction: function() {
|
clickedFunction: function() {
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ PageType {
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
headerText: qsTr("Server IP address [:port]")
|
headerText: qsTr("Server IP address [:port]")
|
||||||
textFieldPlaceholderText: qsTr("Enter the address in the format 255.255.255.255:88")
|
textFieldPlaceholderText: qsTr("255.255.255.255:88")
|
||||||
textField.validator: RegularExpressionValidator {
|
textField.validator: RegularExpressionValidator {
|
||||||
regularExpression: InstallController.ipAddressPortRegExp()
|
regularExpression: InstallController.ipAddressPortRegExp()
|
||||||
}
|
}
|
||||||
|
|
@ -60,13 +60,14 @@ PageType {
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
headerText: qsTr("Login to connect via SSH")
|
headerText: qsTr("Login to connect via SSH")
|
||||||
|
textFieldPlaceholderText: "root"
|
||||||
}
|
}
|
||||||
|
|
||||||
TextFieldWithHeaderType {
|
TextFieldWithHeaderType {
|
||||||
id: secretData
|
id: secretData
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
headerText: qsTr("Password / Private key")
|
headerText: qsTr("Password / SSH private key")
|
||||||
textField.echoMode: TextInput.Password
|
textField.echoMode: TextInput.Password
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,7 @@ PageType {
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
|
|
||||||
headerText: qsTr("Connection protocol")
|
headerText: qsTr("VPN protocol")
|
||||||
descriptionText: qsTr("Choose the one with the highest priority for you. Later, you can install other protocols and additional services, such as DNS proxy and SFTP.")
|
descriptionText: qsTr("Choose the one with the highest priority for you. Later, you can install other protocols and additional services, such as DNS proxy and SFTP.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,8 @@ PageType {
|
||||||
Layout.leftMargin: 16
|
Layout.leftMargin: 16
|
||||||
Layout.rightMargin: 16
|
Layout.rightMargin: 16
|
||||||
|
|
||||||
text: qsTr("A free service to create a personal VPN on your server. We help you access blocked content without exposing your privacy even to VPN providers.")
|
text: qsTr("Free service for creating a personal VPN on your server.") +
|
||||||
|
qsTr(" Helps you access blocked content without revealing your privacy, even to VPN providers.")
|
||||||
}
|
}
|
||||||
|
|
||||||
BasicButtonType {
|
BasicButtonType {
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ PageType {
|
||||||
|
|
||||||
QtObject {
|
QtObject {
|
||||||
id: amneziaConnectionFormat
|
id: amneziaConnectionFormat
|
||||||
property string name: qsTr("For the AmnesiaVPN app")
|
property string name: qsTr("For the AmneziaVPN app")
|
||||||
property var type: PageShare.ConfigType.AmneziaConnection
|
property var type: PageShare.ConfigType.AmneziaConnection
|
||||||
}
|
}
|
||||||
QtObject {
|
QtObject {
|
||||||
|
|
@ -135,7 +135,7 @@ PageType {
|
||||||
checked: root.currentIndex === 1
|
checked: root.currentIndex === 1
|
||||||
|
|
||||||
implicitWidth: (root.width - 32) / 2
|
implicitWidth: (root.width - 32) / 2
|
||||||
text: qsTr("Full")
|
text: qsTr("Full access")
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
accessTypeSelector.currentIndex = 1
|
accessTypeSelector.currentIndex = 1
|
||||||
|
|
@ -194,6 +194,8 @@ PageType {
|
||||||
protocolSelector.visible = true
|
protocolSelector.visible = true
|
||||||
root.shareButtonEnabled = false
|
root.shareButtonEnabled = false
|
||||||
} else {
|
} else {
|
||||||
|
shareConnectionDrawer.headerText = qsTr("Accessing ") + serverSelector.text
|
||||||
|
shareConnectionDrawer.configContentHeaderText = qsTr("File with connection settings to ") + serverSelector.text
|
||||||
serverSelector.menuVisible = false
|
serverSelector.menuVisible = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue