Enter active profile on VPN status selection
Rename selectedIndexPath to activeIndexPath.
This commit is contained in:
parent
91b4992790
commit
5aadde5065
|
@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
|
||||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- VPN status shortcut, enters active profile on selection.
|
||||||
|
|
||||||
## 1.4.0 Beta 1657 (2019-04-08)
|
## 1.4.0 Beta 1657 (2019-04-08)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
|
@ -165,6 +165,13 @@ class OrganizerViewController: UITableViewController, TableModelHost {
|
||||||
|
|
||||||
// MARK: Actions
|
// MARK: Actions
|
||||||
|
|
||||||
|
private func selectActiveProfile() {
|
||||||
|
guard let activeIndexPath = activeIndexPath, let cell = tableView.cellForRow(at: activeIndexPath) else {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
perform(segue: StoryboardSegue.Organizer.selectProfileSegueIdentifier, sender: cell)
|
||||||
|
}
|
||||||
|
|
||||||
private func addNewProvider() {
|
private func addNewProvider() {
|
||||||
var names = Set(InfrastructureFactory.shared.allNames)
|
var names = Set(InfrastructureFactory.shared.allNames)
|
||||||
var createdNames: [Infrastructure.Name] = []
|
var createdNames: [Infrastructure.Name] = []
|
||||||
|
@ -483,7 +490,7 @@ extension OrganizerViewController {
|
||||||
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
|
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
|
||||||
switch model.row(at: indexPath) {
|
switch model.row(at: indexPath) {
|
||||||
case .connectionStatus:
|
case .connectionStatus:
|
||||||
break
|
selectActiveProfile()
|
||||||
|
|
||||||
case .profile:
|
case .profile:
|
||||||
// selectedProfileId = profile(at: indexPath).id
|
// selectedProfileId = profile(at: indexPath).id
|
||||||
|
|
Loading…
Reference in New Issue