Skip to content

Commit

Permalink
backport: remove support for iOS 14
Browse files Browse the repository at this point in the history
Signed-off-by: 82Flex <[email protected]>
  • Loading branch information
Lessica committed Jan 13, 2024
1 parent 23b03ea commit 2889768
Show file tree
Hide file tree
Showing 12 changed files with 23 additions and 67 deletions.
31 changes: 7 additions & 24 deletions Reveil.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@
CC549F072AFA9F1800219CF8 /* EntryUpdater.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC549F062AFA9F1800219CF8 /* EntryUpdater.swift */; };
CC5AE1BB2AD1A4420087F082 /* SocketAddress.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC5AE1BA2AD1A4420087F082 /* SocketAddress.swift */; };
CC5AE1BF2AD2F2010087F082 /* ifaddrs_safe.swift in Sources */ = {isa = PBXBuildFile; fileRef = CC5AE1BE2AD2F2010087F082 /* ifaddrs_safe.swift */; };
CC7C87942B4C459300B6A639 /* SwiftUIBackports in Frameworks */ = {isa = PBXBuildFile; productRef = CC7C87932B4C459300B6A639 /* SwiftUIBackports */; };
CC7DC2912AF3EB1300D50EDC /* library_stub.h in Headers */ = {isa = PBXBuildFile; fileRef = CC7DC2902AF3EB1300D50EDC /* library_stub.h */; settings = {ATTRIBUTES = (Public, ); }; };
CC7DC29B2AF3EBD600D50EDC /* library_stub.m in Sources */ = {isa = PBXBuildFile; fileRef = CC7DC29A2AF3EBD600D50EDC /* library_stub.m */; };
CC7DC29D2AF3ECA500D50EDC /* library_stub.zip in Resources */ = {isa = PBXBuildFile; fileRef = CC7DC29C2AF3ECA500D50EDC /* library_stub.zip */; };
Expand Down Expand Up @@ -371,7 +370,6 @@
CC3F942F2B5240A300E67A19 /* ColorfulX in Frameworks */,
CCD54D2C2AD9047D007ED1AF /* Collections in Frameworks */,
CCA0956D2AE8D5E900F5E55F /* UIKit.framework in Frameworks */,
CC7C87942B4C459300B6A639 /* SwiftUIBackports in Frameworks */,
CCD54D2E2AD9047D007ED1AF /* DequeModule in Frameworks */,
5024F6EC2B1829EE000CEAB5 /* library_stub.framework in Frameworks */,
CCA0956F2AE8D5EE00F5E55F /* SwiftUI.framework in Frameworks */,
Expand Down Expand Up @@ -826,7 +824,6 @@
CCD54D2F2AD9047D007ED1AF /* OrderedCollections */,
0F08193C2ADAF1C600BB626C /* DictionaryCoder */,
CC7DC2A02AF3EEBB00D50EDC /* ZIPFoundation */,
CC7C87932B4C459300B6A639 /* SwiftUIBackports */,
CC3F942E2B5240A300E67A19 /* ColorfulX */,
);
productName = Reveil;
Expand Down Expand Up @@ -887,7 +884,6 @@
0F08193B2ADAF1C600BB626C /* XCRemoteSwiftPackageReference "DictionaryCoder" */,
CC7DC29F2AF3EEBB00D50EDC /* XCRemoteSwiftPackageReference "ZIPFoundation" */,
0FA065832B3D8436000A7ECE /* XCRemoteSwiftPackageReference "swift-argument-parser" */,
CC7C87922B4C459300B6A639 /* XCRemoteSwiftPackageReference "SwiftUIBackports" */,
CC3F942D2B5240A300E67A19 /* XCRemoteSwiftPackageReference "ColorfulX" */,
);
productRefGroup = CC4AE2B52ACAA4B400DA23AC /* Products */;
Expand Down Expand Up @@ -1143,7 +1139,7 @@
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MACOSX_DEPLOYMENT_TARGET = 11.0;
MACOSX_DEPLOYMENT_TARGET = 12.0;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)";
Expand All @@ -1162,7 +1158,7 @@
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MACOSX_DEPLOYMENT_TARGET = 11.0;
MACOSX_DEPLOYMENT_TARGET = 12.0;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = macosx;
SWIFT_VERSION = 5.0;
Expand Down Expand Up @@ -1314,7 +1310,7 @@
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -1357,7 +1353,7 @@
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -1393,7 +1389,7 @@
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_NSHumanReadableCopyright = "";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"@executable_path/Frameworks",
"@loader_path/Frameworks",
Expand Down Expand Up @@ -1441,7 +1437,7 @@
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_NSHumanReadableCopyright = "";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"@executable_path/Frameworks",
"@loader_path/Frameworks",
Expand Down Expand Up @@ -1531,17 +1527,9 @@
CC3F942D2B5240A300E67A19 /* XCRemoteSwiftPackageReference "ColorfulX" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/Lakr233/ColorfulX.git";
requirement = {
branch = "bugfix/displaylink-memory-leaks";
kind = branch;
};
};
CC7C87922B4C459300B6A639 /* XCRemoteSwiftPackageReference "SwiftUIBackports" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/shaps80/SwiftUIBackports.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 2.8.0;
minimumVersion = 2.3.0;
};
};
CC7DC29F2AF3EEBB00D50EDC /* XCRemoteSwiftPackageReference "ZIPFoundation" */ = {
Expand Down Expand Up @@ -1578,11 +1566,6 @@
package = CC3F942D2B5240A300E67A19 /* XCRemoteSwiftPackageReference "ColorfulX" */;
productName = ColorfulX;
};
CC7C87932B4C459300B6A639 /* SwiftUIBackports */ = {
isa = XCSwiftPackageProductDependency;
package = CC7C87922B4C459300B6A639 /* XCRemoteSwiftPackageReference "SwiftUIBackports" */;
productName = SwiftUIBackports;
};
CC7DC2A02AF3EEBB00D50EDC /* ZIPFoundation */ = {
isa = XCSwiftPackageProductDependency;
package = CC7DC29F2AF3EEBB00D50EDC /* XCRemoteSwiftPackageReference "ZIPFoundation" */;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/Lakr233/ColorfulX.git",
"state" : {
"branch" : "bugfix/displaylink-memory-leaks",
"revision" : "019149d122448193471a94e85df0e4f943e3dc5f"
"revision" : "a422557a7c2cac7c6348f6a650dfa08260e6c4e6",
"version" : "2.3.0"
}
},
{
Expand Down Expand Up @@ -45,24 +45,6 @@
"version" : "1.0.6"
}
},
{
"identity" : "swiftbackports",
"kind" : "remoteSourceControl",
"location" : "https://github.com/shaps80/SwiftBackports",
"state" : {
"revision" : "ddca6a237c1ba2291d5a3cc47ec8480ce6e9f805",
"version" : "1.0.3"
}
},
{
"identity" : "swiftuibackports",
"kind" : "remoteSourceControl",
"location" : "https://github.com/shaps80/SwiftUIBackports.git",
"state" : {
"revision" : "3042f0cf4b9f0d5b0bb08ad17f742a43bc4fdfc5",
"version" : "2.8.0"
}
},
{
"identity" : "zipfoundation",
"kind" : "remoteSourceControl",
Expand Down
7 changes: 3 additions & 4 deletions Reveil/ContentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import UIKit
import SwiftUI
import SwiftUIBackports

struct ContentView: View {
@Environment(\.horizontalSizeClass) private var horizontalSizeClass
Expand Down Expand Up @@ -67,7 +66,7 @@ struct SidebarView: View {
var body: some View {
NavigationView {
List {
Backport.Section(NSLocalizedString("DASHBOARD", comment: "Dashboard")) {
Section(NSLocalizedString("DASHBOARD", comment: "Dashboard")) {
NavigationLink {
DashboardView()
.navigationTitle(NSLocalizedString("DASHBOARD", comment: "Dashboard"))
Expand All @@ -77,11 +76,11 @@ struct SidebarView: View {
}
}

Backport.Section(NSLocalizedString("DETAILS", comment: "Details")) {
Section(NSLocalizedString("DETAILS", comment: "Details")) {
DetailsView.createDetailsList()
}

Backport.Section(NSLocalizedString("ABOUT", comment: "About")) {
Section(NSLocalizedString("ABOUT", comment: "About")) {
NavigationLink {
AboutView()
.background(ColorfulBackground())
Expand Down
5 changes: 2 additions & 3 deletions Reveil/Pages/DashboardView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

struct DashboardView: View {
@StateObject private var viewModel = Dashboard.shared
Expand All @@ -31,11 +30,11 @@ struct DashboardView: View {
.foregroundColor(Color(PlatformColor.secondarySystemBackgroundAlias))
.opacity(0.25)
)
.backport.overlay {
.overlay {
RoundedRectangle(cornerRadius: 4)
.stroke(Color(PlatformColor.separatorAlias), lineWidth: 1)
}
.backport.overlay { navigationLinkBuilder(entry) }
.overlay { navigationLinkBuilder(entry) }
}
.padding(entry === viewModel.entries.last ? .bottom : [], 8)
.listSectionSeparator(hidden: true)
Expand Down
3 changes: 1 addition & 2 deletions Reveil/Pages/Details/FileSystemsListView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

struct FileSystemsListView: View, ModuleListView {
let module: Module = FileSystems.shared
Expand All @@ -19,7 +18,7 @@ struct FileSystemsListView: View, ModuleListView {
}
}

@Environment(\.backportDismiss) private var dismissAction
@Environment(\.dismiss) private var dismissAction

@State var items: [FileSystem] = []

Expand Down
2 changes: 1 addition & 1 deletion Reveil/Pages/Details/NetworkDetailsListView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ struct NetworkDetailsListView: View, ModuleListView {

init?(entryKey _: EntryKey) { nil }

@Environment(\.backportDismiss) private var dismissAction
@Environment(\.dismiss) private var dismissAction

@State var items: [NetworkPrefix] = []

Expand Down
3 changes: 1 addition & 2 deletions Reveil/Pages/Details/NetworkInterfacesListView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

struct NetworkInterfacesListView: View, ModuleListView {
let module: Module = NetworkInterfaces.shared
Expand All @@ -19,7 +18,7 @@ struct NetworkInterfacesListView: View, ModuleListView {
}
}

@Environment(\.backportDismiss) private var dismissAction
@Environment(\.dismiss) private var dismissAction

@State var items: [NetworkInterface] = []

Expand Down
7 changes: 3 additions & 4 deletions Reveil/Pages/DetailsListView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

struct DetailsListView: View, FieldCellDelegate {
let basicEntries: [BasicEntry]
Expand All @@ -16,7 +15,7 @@ struct DetailsListView: View, FieldCellDelegate {

private let pasteboard = UIPasteboard.general

@Environment(\.backportDismiss) private var dismissAction
@Environment(\.dismiss) private var dismissAction
@EnvironmentObject private var highlightedEntryKey: HighlightedEntryKey

@State private var selectedEntryKey: EntryKey?
Expand Down Expand Up @@ -54,7 +53,7 @@ struct DetailsListView: View, FieldCellDelegate {
}
.listStyle(.plain)
.frame(maxWidth: .infinity)
.backport.overlay(alignment: .bottom) { toastOverlay() }
.overlay(alignment: .bottom) { toastOverlay() }
.onAppear {
if let object = highlightedEntryKey.object {
selectedEntryKeys.removeAll(keepingCapacity: true)
Expand Down Expand Up @@ -121,7 +120,7 @@ struct DetailsListView: View, FieldCellDelegate {
}
.listSectionSeparator(hidden: true)
} else {
Backport.Section(entryGroup.title) {
Section(entryGroup.title) {
sectionBuilder(entryGroup.entries)
}
.listSectionSeparator(hidden: true)
Expand Down
3 changes: 1 addition & 2 deletions Reveil/Pages/SecurityView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@
//

import SwiftUI
import SwiftUIBackports

struct SecurityView: View {
@StateObject private var securityModel = Security.shared

@Environment(\.backportDismiss) private var dismissAction
@Environment(\.dismiss) private var dismissAction

var body: some View {
DetailsListView(basicEntries: securityModel.basicEntries)
Expand Down
5 changes: 2 additions & 3 deletions Reveil/Views/Dashboard/CheckmarkWidget.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import ColorfulX
import SwiftUI
import SwiftUIBackports

struct CheckmarkWidget: View {
@StateObject var securityModel: Security = .shared
Expand Down Expand Up @@ -99,7 +98,7 @@ struct CheckmarkWidget: View {
}
.frame(maxWidth: .infinity, alignment: .leading)
.padding(.all, 12)
.backport.background {
.background {
if usesLegacyStyle {
RoundedRectangle(cornerRadius: 4)
.foregroundColor(backgroundColor)
Expand All @@ -110,7 +109,7 @@ struct CheckmarkWidget: View {
.clipShape(RoundedRectangle(cornerRadius: 4))
}
}
.backport.overlay {
.overlay {
if usesLegacyStyle && !isInsecure {
RoundedRectangle(cornerRadius: 4)
.stroke(Color(PlatformColor.separatorAlias), lineWidth: 1)
Expand Down
1 change: 0 additions & 1 deletion Reveil/Views/Details/FieldCell.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

private struct FieldCell_Internal: View {
let label: String
Expand Down
1 change: 0 additions & 1 deletion Reveil/Views/Details/ToastView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import SwiftUI
import SwiftUIBackports

struct ToastView: View {
let label: String
Expand Down

0 comments on commit 2889768

Please sign in to comment.