From f3df03de9bf58325309499ffa4420a3ea468db11 Mon Sep 17 00:00:00 2001 From: Davide De Rosa Date: Wed, 17 Oct 2018 15:30:40 +0200 Subject: [PATCH] Disclose organizer profiles Use text instead of checkmark to mark active profile. Allows restoring disclosure indicator. --- .../Scenes/Organizer/OrganizerViewController.swift | 2 +- Passepartout/Resources/en.lproj/Localizable.strings | 1 + Passepartout/Sources/SwiftGen+Strings.swift | 8 ++++++++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift b/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift index 70116780..b6b703a2 100644 --- a/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift +++ b/Passepartout-iOS/Scenes/Organizer/OrganizerViewController.swift @@ -289,7 +289,7 @@ extension OrganizerViewController { let cell = Cells.setting.dequeue(from: tableView, for: indexPath) let rowProfile = profile(at: indexPath) cell.leftText = rowProfile.title - cell.applyChecked(service.isActiveProfile(rowProfile), Theme.current) + cell.rightText = service.isActiveProfile(rowProfile) ? L10n.Organizer.Cells.Profile.Value.current : nil return cell case .addProvider: diff --git a/Passepartout/Resources/en.lproj/Localizable.strings b/Passepartout/Resources/en.lproj/Localizable.strings index 621bf82b..1bc3b9cf 100644 --- a/Passepartout/Resources/en.lproj/Localizable.strings +++ b/Passepartout/Resources/en.lproj/Localizable.strings @@ -31,6 +31,7 @@ "organizer.sections.providers.footer" = "Here you find a few public infrastructures offering preset configuration profiles."; "organizer.sections.hosts.header" = "Hosts"; "organizer.sections.hosts.footer" = "Import hosts from raw .ovpn configuration files."; +"organizer.cells.profile.value.current" = "In use"; "organizer.cells.add_provider.caption" = "Add new network"; "organizer.cells.add_host.caption" = "Add new host"; "organizer.cells.about.caption" = "About %@"; diff --git a/Passepartout/Sources/SwiftGen+Strings.swift b/Passepartout/Sources/SwiftGen+Strings.swift index 37b10b85..2b2ed25d 100644 --- a/Passepartout/Sources/SwiftGen+Strings.swift +++ b/Passepartout/Sources/SwiftGen+Strings.swift @@ -344,6 +344,14 @@ internal enum L10n { internal static let caption = L10n.tr("Localizable", "organizer.cells.add_provider.caption") } + internal enum Profile { + + internal enum Value { + /// In use + internal static let current = L10n.tr("Localizable", "organizer.cells.profile.value.current") + } + } + internal enum Uninstall { /// Delete VPN profile internal static let caption = L10n.tr("Localizable", "organizer.cells.uninstall.caption")