Commit 81e9691b authored by Jose Blaya's avatar Jose Blaya
Browse files

- Update Settings screen

- Update strings
parent 7d18089a
......@@ -91,7 +91,9 @@ class SettingsViewController: AutolayoutViewController {
case encryption
case applicationSettings
case autoConnectSettings
case contentBlocker
case applicationInformation
......@@ -105,6 +107,7 @@ class SettingsViewController: AutolayoutViewController {
.connection,
.encryption,
.applicationSettings,
.autoConnectSettings,
.applicationInformation,
.reset,
.contentBlocker
......@@ -125,6 +128,9 @@ class SettingsViewController: AutolayoutViewController {
.encryptionHandshake
],
.applicationSettings: [], // dynamic
.autoConnectSettings: [
.shouldConnectWithUnsecureNetworks
],
.contentBlocker: [
.contentBlockerState,
.contentBlockerRefreshRules
......@@ -523,14 +529,12 @@ class SettingsViewController: AutolayoutViewController {
rowsBySection[.applicationSettings] = [
.darkTheme,
.automaticReconnection,
.shouldConnectWithUnsecureNetworks,
.mace
]
} else {
rowsBySection[.applicationSettings] = [
.darkTheme,
.automaticReconnection,
.shouldConnectWithUnsecureNetworks
]
}
if !Flags.shared.enablesContentBlockerSetting {
......@@ -626,7 +630,10 @@ extension SettingsViewController: UITableViewDataSource, UITableViewDelegate {
case .applicationSettings:
return L10n.Settings.ApplicationSettings.title
case .autoConnectSettings:
return nil
case .contentBlocker:
return L10n.Settings.ContentBlocker.title
......@@ -652,6 +659,9 @@ extension SettingsViewController: UITableViewDataSource, UITableViewDelegate {
}
return footer.joined(separator: "\n\n")
case .autoConnectSettings:
return L10n.Settings.Hotspothelper.description
case .reset:
return L10n.Settings.Reset.footer
......@@ -755,7 +765,7 @@ extension SettingsViewController: UITableViewDataSource, UITableViewDelegate {
switchPersistent.isOn = pendingPreferences.isPersistentConnection
case .shouldConnectWithUnsecureNetworks:
cell.textLabel?.text = L10n.Settings.Hotspothelper.description
cell.textLabel?.text = L10n.Settings.Hotspothelper.title
cell.detailTextLabel?.text = nil
cell.accessoryView = switchAutoJoinWiFi
cell.selectionStyle = .none
......
......@@ -194,7 +194,7 @@ internal enum L10n {
internal enum Hotspothelper {
internal enum Display {
/// 🛡 Protect your connection with PIA
/// 🛡 Open Network: Use PIA for Protection.
internal static let name = L10n.tr("Localizable", "hotspothelper.display.name")
}
}
......@@ -440,8 +440,10 @@ internal enum L10n {
}
}
internal enum Hotspothelper {
/// Auto connect WiFi
/// VPN WiFi Protection automatically connects the VPN when connecting to an Open network.
internal static let description = L10n.tr("Localizable", "settings.hotspothelper.description")
/// VPN WiFi Protection
internal static let title = L10n.tr("Localizable", "settings.hotspothelper.title")
}
internal enum Reset {
/// This will reset all of the above settings to default.
......
......@@ -199,5 +199,6 @@
// HOTSPOT HELPER
"settings.hotspothelper.description" = "Auto connect WiFi";
"hotspothelper.display.name" = "🛡 Protect your connection with PIA";
"settings.hotspothelper.title" = "VPN WiFi Protection";
"settings.hotspothelper.description" = "VPN WiFi Protection automatically connects the VPN when connecting to an Open network.";
"hotspothelper.display.name" = "🛡 Open Network: Use PIA for Protection.";
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment