aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/Coordinators/AppCoordinator+TunnelInfoTableViewControllerDelegate.swift
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--WireGuard/Coordinators/AppCoordinator+TunnelInfoTableViewControllerDelegate.swift32
1 files changed, 0 insertions, 32 deletions
diff --git a/WireGuard/Coordinators/AppCoordinator+TunnelInfoTableViewControllerDelegate.swift b/WireGuard/Coordinators/AppCoordinator+TunnelInfoTableViewControllerDelegate.swift
deleted file mode 100644
index aa6f3f2..0000000
--- a/WireGuard/Coordinators/AppCoordinator+TunnelInfoTableViewControllerDelegate.swift
+++ /dev/null
@@ -1,32 +0,0 @@
-//
-// Copyright © 2018 WireGuard LLC. All rights reserved.
-//
-
-import Foundation
-import NetworkExtension
-
-extension AppCoordinator: TunnelInfoTableViewControllerDelegate {
- func connect(tunnel: Tunnel, tunnelInfoTableViewController: TunnelInfoTableViewController) {
- connect(tunnel: tunnel)
- }
-
- func disconnect(tunnel: Tunnel, tunnelInfoTableViewController: TunnelInfoTableViewController) {
- disconnect(tunnel: tunnel)
- }
-
- func status(for tunnel: Tunnel, tunnelInfoTableViewController: TunnelInfoTableViewController) -> NEVPNStatus {
- let session = self.providerManager(for: tunnel)?.connection as? NETunnelProviderSession
- return session?.status ?? .invalid
- }
-
- func configure(tunnel: Tunnel, tunnelInfoTableViewController: TunnelInfoTableViewController) {
- let editContext = persistentContainer.newBackgroundContext()
- var backgroundTunnel: Tunnel?
- editContext.performAndWait {
- backgroundTunnel = editContext.object(with: tunnel.objectID) as? Tunnel
- }
-
- showTunnelConfigurationViewController(tunnel: backgroundTunnel, context: editContext)
- }
-
-}