diff options
author | Jeroen Leenarts <jeroen.leenarts@gmail.com> | 2018-05-24 22:07:04 +0200 |
---|---|---|
committer | Jeroen Leenarts <jeroen.leenarts@gmail.com> | 2018-05-24 22:07:04 +0200 |
commit | 972407344781dde2b2a2c0d1b3405a042eb73c33 (patch) | |
tree | 8bc49a2f3b93d35a73936540731ed831f5854c2e /WireGuard/ViewControllers | |
parent | Basic setup of ConnectionsTableViewController. (diff) | |
download | wireguard-apple-972407344781dde2b2a2c0d1b3405a042eb73c33.tar.xz wireguard-apple-972407344781dde2b2a2c0d1b3405a042eb73c33.zip |
Add bare bones `ProfileConfigurationTableViewController`.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'WireGuard/ViewControllers')
-rw-r--r-- | WireGuard/ViewControllers/ProfileConfigurationTableViewController.swift | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/WireGuard/ViewControllers/ProfileConfigurationTableViewController.swift b/WireGuard/ViewControllers/ProfileConfigurationTableViewController.swift new file mode 100644 index 0000000..39290d4 --- /dev/null +++ b/WireGuard/ViewControllers/ProfileConfigurationTableViewController.swift @@ -0,0 +1,51 @@ +// +// ProfileConfigurationTableViewController.swift +// WireGuard +// +// Created by Jeroen Leenarts on 24-05-18. +// Copyright © 2018 Wireguard. All rights reserved. +// + +import UIKit +import CoreData +import BNRCoreDataStack + +protocol ProfileConfigurationTableViewControllerDelegate: class { +} + +class ProfileConfigurationTableViewController: UITableViewController { + var viewContext: NSManagedObjectContext! + weak var delegate: ProfileConfigurationTableViewControllerDelegate? + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + return 3 + } + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + switch indexPath.row { + case 0: + return tableView.dequeueReusableCell(type: InterfaceTableViewCell.self, for: indexPath) + case 1: + return tableView.dequeueReusableCell(type: PeerTableViewCell.self, for: indexPath) + default: + return tableView.dequeueReusableCell(type: AddPeerTableViewCell.self, for: indexPath) + } + } +} + +class InterfaceTableViewCell: UITableViewCell { + +} + +class PeerTableViewCell: UITableViewCell { + +} + +class AddPeerTableViewCell: UITableViewCell { + +} + +extension ProfileConfigurationTableViewController: Identifyable {} +extension InterfaceTableViewCell: Identifyable {} +extension PeerTableViewCell: Identifyable {} +extension AddPeerTableViewCell: Identifyable {} |