From 35866d558ddac7b764879340ea4ac6aabe3e5939 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Mon, 17 Jun 2019 15:50:17 -0500 Subject: [PATCH] Only display active accounts for OPML import on iOS --- Frameworks/Articles/Articles.xcodeproj/project.pbxproj | 2 -- iOS/Settings/SettingsView.swift | 10 +++++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Frameworks/Articles/Articles.xcodeproj/project.pbxproj b/Frameworks/Articles/Articles.xcodeproj/project.pbxproj index 12e1f6baa..f501f687a 100644 --- a/Frameworks/Articles/Articles.xcodeproj/project.pbxproj +++ b/Frameworks/Articles/Articles.xcodeproj/project.pbxproj @@ -217,13 +217,11 @@ TargetAttributes = { 844BEE5A1F0AB3C8004AB7CD = { CreatedOnToolsVersion = 8.3.2; - DevelopmentTeam = M8L2WTLA8W; LastSwiftMigration = 0830; ProvisioningStyle = Automatic; }; 844BEE631F0AB3C9004AB7CD = { CreatedOnToolsVersion = 8.3.2; - DevelopmentTeam = M8L2WTLA8W; ProvisioningStyle = Automatic; }; }; diff --git a/iOS/Settings/SettingsView.swift b/iOS/Settings/SettingsView.swift index cf0ad70f3..2b654aca6 100644 --- a/iOS/Settings/SettingsView.swift +++ b/iOS/Settings/SettingsView.swift @@ -84,7 +84,7 @@ struct SettingsView : View { var createSubscriptionsImportAccounts: ActionSheet { var buttons = [ActionSheet.Button]() - for account in viewModel.accounts { + for account in viewModel.activeAccounts { let button = ActionSheet.Button.default(Text(verbatim: account.nameForDisplay)) { self.subscriptionsImportAccounts = nil self.subscriptionsImportDocumentPicker = Modal(SettingsSubscriptionsImportDocumentPickerView(account: account)) @@ -127,6 +127,14 @@ struct SettingsView : View { } } + var activeAccounts: [Account] { + get { + return AccountManager.shared.sortedActiveAccounts + } + set { + } + } + var sortOldestToNewest: Bool { get { return AppDefaults.timelineSortDirection == .orderedDescending