mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2024-12-22 15:50:17 +01:00
Remove unused AddFeedType.
This commit is contained in:
parent
c1f6026495
commit
7fe5f94262
@ -18,7 +18,6 @@ protocol AddFeedFolderViewControllerDelegate {
|
|||||||
final class AddFeedFolderViewController: UITableViewController {
|
final class AddFeedFolderViewController: UITableViewController {
|
||||||
|
|
||||||
var delegate: AddFeedFolderViewControllerDelegate?
|
var delegate: AddFeedFolderViewControllerDelegate?
|
||||||
var addFeedType = AddFeedType.web
|
|
||||||
var initialContainer: Container?
|
var initialContainer: Container?
|
||||||
|
|
||||||
var containers = [Container]()
|
var containers = [Container]()
|
||||||
@ -26,14 +25,7 @@ final class AddFeedFolderViewController: UITableViewController {
|
|||||||
override func viewDidLoad() {
|
override func viewDidLoad() {
|
||||||
super.viewDidLoad()
|
super.viewDidLoad()
|
||||||
|
|
||||||
var sortedActiveAccounts: [Account]
|
for account in AccountManager.shared.sortedActiveAccounts {
|
||||||
if addFeedType == .web {
|
|
||||||
sortedActiveAccounts = AccountManager.shared.sortedActiveAccounts
|
|
||||||
} else {
|
|
||||||
sortedActiveAccounts = AccountManager.shared.sortedActiveAccounts.filter { $0.accountType == .onMyMac || $0.accountType == .cloudKit }
|
|
||||||
}
|
|
||||||
|
|
||||||
for account in sortedActiveAccounts {
|
|
||||||
containers.append(account)
|
containers.append(account)
|
||||||
if let sortedFolders = account.sortedFolders {
|
if let sortedFolders = account.sortedFolders {
|
||||||
containers.append(contentsOf: sortedFolders)
|
containers.append(contentsOf: sortedFolders)
|
||||||
|
@ -13,10 +13,6 @@ import Parser
|
|||||||
import Core
|
import Core
|
||||||
import CommonErrors
|
import CommonErrors
|
||||||
|
|
||||||
enum AddFeedType {
|
|
||||||
case web
|
|
||||||
}
|
|
||||||
|
|
||||||
final class AddFeedViewController: UITableViewController {
|
final class AddFeedViewController: UITableViewController {
|
||||||
|
|
||||||
@IBOutlet weak var activityIndicator: UIActivityIndicatorView!
|
@IBOutlet weak var activityIndicator: UIActivityIndicatorView!
|
||||||
@ -30,7 +26,6 @@ final class AddFeedViewController: UITableViewController {
|
|||||||
private var folderLabel = ""
|
private var folderLabel = ""
|
||||||
private var userCancelled = false
|
private var userCancelled = false
|
||||||
|
|
||||||
var addFeedType = AddFeedType.web
|
|
||||||
var initialFeed: String?
|
var initialFeed: String?
|
||||||
var initialFeedName: String?
|
var initialFeedName: String?
|
||||||
|
|
||||||
@ -39,11 +34,6 @@ final class AddFeedViewController: UITableViewController {
|
|||||||
override func viewDidLoad() {
|
override func viewDidLoad() {
|
||||||
super.viewDidLoad()
|
super.viewDidLoad()
|
||||||
|
|
||||||
switch addFeedType {
|
|
||||||
default:
|
|
||||||
break
|
|
||||||
}
|
|
||||||
|
|
||||||
activityIndicator.isHidden = true
|
activityIndicator.isHidden = true
|
||||||
activityIndicator.color = .label
|
activityIndicator.color = .label
|
||||||
|
|
||||||
@ -155,7 +145,6 @@ final class AddFeedViewController: UITableViewController {
|
|||||||
navController.modalPresentationStyle = .currentContext
|
navController.modalPresentationStyle = .currentContext
|
||||||
let folderViewController = navController.topViewController as! AddFeedFolderViewController
|
let folderViewController = navController.topViewController as! AddFeedFolderViewController
|
||||||
folderViewController.delegate = self
|
folderViewController.delegate = self
|
||||||
folderViewController.addFeedType = addFeedType
|
|
||||||
folderViewController.initialContainer = container
|
folderViewController.initialContainer = container
|
||||||
present(navController, animated: true)
|
present(navController, animated: true)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user