aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift
diff options
context:
space:
mode:
authorRoopesh Chander <roop@roopc.net>2018-10-23 22:18:45 +0530
committerRoopesh Chander <roop@roopc.net>2018-10-27 15:13:01 +0530
commitc14d816b879d05b876bc486ff0bfd86f3f39b5a1 (patch)
tree90eb3fb5b9790d3ea72bc1635ba752b527c2714c /WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift
parentTunnel view model: Add copy public key (diff)
downloadwireguard-apple-c14d816b879d05b876bc486ff0bfd86f3f39b5a1.tar.xz
wireguard-apple-c14d816b879d05b876bc486ff0bfd86f3f39b5a1.zip
Tunnel detail: Start off with the tunnel detail view
Signed-off-by: Roopesh Chander <roop@roopc.net>
Diffstat (limited to '')
-rw-r--r--WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift12
1 files changed, 12 insertions, 0 deletions
diff --git a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift
index 2a57393..35e90b0 100644
--- a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift
+++ b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift
@@ -81,6 +81,18 @@ extension TunnelsListTableViewController {
}
}
+// MARK: UITableViewDelegate
+
+extension TunnelsListTableViewController {
+ override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
+ guard let tunnelsManager = tunnelsManager else { return }
+ let tunnelConfiguration = tunnelsManager.tunnel(at: indexPath.row).tunnelProvider.tunnelConfiguration
+ let tunnelDetailVC = TunnelDetailTableViewController(tunnelsManager: tunnelsManager,
+ tunnelConfiguration: tunnelConfiguration)
+ showDetailViewController(tunnelDetailVC, sender: self) // Shall get propagated up to the split-vc
+ }
+}
+
// MARK: TunnelsManagerDelegate
extension TunnelsListTableViewController: TunnelsManagerDelegate {