From bf9cfda127e19a4345de0255dae3bd181dce01b4 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Tue, 23 Apr 2019 04:50:06 -0500 Subject: [PATCH] Remove Add Account from the Add dialog. --- NetNewsWire.xcodeproj/project.pbxproj | 4 -- iOS/Add/Add.storyboard | 51 ++---------------------- iOS/Add/AddAccountViewController.swift | 30 -------------- iOS/Add/AddContainerViewController.swift | 13 +----- 4 files changed, 5 insertions(+), 93 deletions(-) delete mode 100644 iOS/Add/AddAccountViewController.swift diff --git a/NetNewsWire.xcodeproj/project.pbxproj b/NetNewsWire.xcodeproj/project.pbxproj index 73719c0f1..a6fb9a0bd 100644 --- a/NetNewsWire.xcodeproj/project.pbxproj +++ b/NetNewsWire.xcodeproj/project.pbxproj @@ -17,7 +17,6 @@ 512E09012268907400BDCFDD /* MasterTableViewSectionHeader.swift in Sources */ = {isa = PBXBuildFile; fileRef = 512E08F722688F7C00BDCFDD /* MasterTableViewSectionHeader.swift */; }; 512E09352268B25900BDCFDD /* UISplitViewController-Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 512E092B2268B25500BDCFDD /* UISplitViewController-Extensions.swift */; }; 512E094D2268B8AB00BDCFDD /* DeleteCommand.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84B99C9C1FAE83C600ECDEDB /* DeleteCommand.swift */; }; - 517D9075226639F500323654 /* AddAccountViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 517D906B2266392900323654 /* AddAccountViewController.swift */; }; 5183CCD0226E1E880010922C /* NonIntrinsicLabel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5183CCCF226E1E880010922C /* NonIntrinsicLabel.swift */; }; 5183CCDA226E31A50010922C /* NonIntrinsicImageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5183CCD9226E31A50010922C /* NonIntrinsicImageView.swift */; }; 519B8D332143397200FA689C /* SharingServiceDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 519B8D322143397200FA689C /* SharingServiceDelegate.swift */; }; @@ -610,7 +609,6 @@ 5127B237222B4849006D641D /* DetailKeyboardShortcuts.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = DetailKeyboardShortcuts.plist; sourceTree = ""; }; 512E08F722688F7C00BDCFDD /* MasterTableViewSectionHeader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MasterTableViewSectionHeader.swift; sourceTree = ""; }; 512E092B2268B25500BDCFDD /* UISplitViewController-Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "UISplitViewController-Extensions.swift"; sourceTree = ""; }; - 517D906B2266392900323654 /* AddAccountViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddAccountViewController.swift; sourceTree = ""; }; 5183CCCF226E1E880010922C /* NonIntrinsicLabel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NonIntrinsicLabel.swift; sourceTree = ""; }; 5183CCD9226E31A50010922C /* NonIntrinsicImageView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NonIntrinsicImageView.swift; sourceTree = ""; }; 519B8D322143397200FA689C /* SharingServiceDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SharingServiceDelegate.swift; sourceTree = ""; }; @@ -976,7 +974,6 @@ 51C452842265093600C03939 /* AddFeedViewController.swift */, 51C452812265093600C03939 /* AddFeedFolderPickerData.swift */, 51C4528B2265095F00C03939 /* AddFolderViewController.swift */, - 517D906B2266392900323654 /* AddAccountViewController.swift */, ); path = Add; sourceTree = ""; @@ -2162,7 +2159,6 @@ 51C45294226509C800C03939 /* SearchFeedDelegate.swift in Sources */, 512E09352268B25900BDCFDD /* UISplitViewController-Extensions.swift in Sources */, 51C452A022650A1900C03939 /* FeedIconDownloader.swift in Sources */, - 517D9075226639F500323654 /* AddAccountViewController.swift in Sources */, 51C4529E22650A1900C03939 /* ImageDownloader.swift in Sources */, 51C45292226509C800C03939 /* TodayFeedDelegate.swift in Sources */, 84F3EE1B20DEC97E003FADEB /* HTMLFeedFinder.swift in Sources */, diff --git a/iOS/Add/Add.storyboard b/iOS/Add/Add.storyboard index 80b100ce0..95c8fb579 100644 --- a/iOS/Add/Add.storyboard +++ b/iOS/Add/Add.storyboard @@ -172,11 +172,13 @@ - + + + + - @@ -341,50 +343,5 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/iOS/Add/AddAccountViewController.swift b/iOS/Add/AddAccountViewController.swift deleted file mode 100644 index 1c6ab89c6..000000000 --- a/iOS/Add/AddAccountViewController.swift +++ /dev/null @@ -1,30 +0,0 @@ -// -// AddAccountViewController.swift -// NetNewsWire -// -// Created by Maurice Parker on 4/16/19. -// Copyright © 2019 Ranchero Software, LLC. All rights reserved. -// - -import UIKit - -class AddAccountViewController: UITableViewController, AddContainerViewControllerChild { - var delegate: AddContainerViewControllerChildDelegate? - - override func viewDidLoad() { - super.viewDidLoad() - - // I couldn't figure out the gap at the top of the UITableView, so I took a hammer to it. - tableView.contentInset = UIEdgeInsets(top: -28, left: 0, bottom: 0, right: 0) - - } - - func cancel() { - - } - - func add() { - - } - -} diff --git a/iOS/Add/AddContainerViewController.swift b/iOS/Add/AddContainerViewController.swift index 5ad0c6878..6e656c350 100644 --- a/iOS/Add/AddContainerViewController.swift +++ b/iOS/Add/AddContainerViewController.swift @@ -45,10 +45,8 @@ class AddContainerViewController: UIViewController { switch sender.selectedSegmentIndex { case 0: switchToFeed() - case 1: - switchToFolder() default: - switchToAccount() + switchToFolder() } } @@ -110,15 +108,6 @@ private extension AddContainerViewController { displayContentController(UIStoryboard.add.instantiateController(ofType: AddFolderViewController.self)) } - func switchToAccount() { - guard !(currentViewController is AddAccountViewController) else { - return - } - resetUI() - hideCurrentController() - displayContentController(UIStoryboard.add.instantiateController(ofType: AddAccountViewController.self)) - } - func resetUI() { addButton.isEnabled = false }