forked from shadowfacts/Tusker
Remove old compilation condition
This commit is contained in:
parent
36a78f1a3c
commit
5a26739b78
|
@ -2632,9 +2632,6 @@
|
||||||
PROVISIONING_PROFILE_SPECIFIER = "";
|
PROVISIONING_PROFILE_SPECIFIER = "";
|
||||||
SUPPORTS_MACCATALYST = YES;
|
SUPPORTS_MACCATALYST = YES;
|
||||||
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
|
||||||
"SWIFT_ACTIVE_COMPILATION_CONDITIONS[sdk=iphoneos15.0]" = "SDK_IOS_15 $(inherited)";
|
|
||||||
"SWIFT_ACTIVE_COMPILATION_CONDITIONS[sdk=iphonesimulator15.0]" = "SDK_IOS_15 $(inherited)";
|
|
||||||
"SWIFT_ACTIVE_COMPILATION_CONDITIONS[sdk=macosx12.0]" = "SDK_IOS_15 $(inherited)";
|
|
||||||
SWIFT_VERSION = 5.0;
|
SWIFT_VERSION = 5.0;
|
||||||
TARGETED_DEVICE_FAMILY = "1,2,6";
|
TARGETED_DEVICE_FAMILY = "1,2,6";
|
||||||
};
|
};
|
||||||
|
|
|
@ -245,7 +245,6 @@ extension ComposeHostingController: ComposeUIStateDelegate {
|
||||||
}
|
}
|
||||||
|
|
||||||
func presentAssetPickerSheet() {
|
func presentAssetPickerSheet() {
|
||||||
#if SDK_IOS_15
|
|
||||||
if #available(iOS 15.0, *) {
|
if #available(iOS 15.0, *) {
|
||||||
let picker = AssetPickerViewController()
|
let picker = AssetPickerViewController()
|
||||||
picker.assetPickerDelegate = self
|
picker.assetPickerDelegate = self
|
||||||
|
@ -258,9 +257,6 @@ extension ComposeHostingController: ComposeUIStateDelegate {
|
||||||
} else {
|
} else {
|
||||||
presentOldAssetPickerSheet()
|
presentOldAssetPickerSheet()
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
presentOldAssetPickerSheet()
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private func presentOldAssetPickerSheet() {
|
private func presentOldAssetPickerSheet() {
|
||||||
|
|
|
@ -326,16 +326,7 @@ class ConversationTableViewController: EnhancedTableViewController {
|
||||||
}
|
}
|
||||||
|
|
||||||
@objc func toggleVisibilityButtonPressed() {
|
@objc func toggleVisibilityButtonPressed() {
|
||||||
#if SDK_IOS_15
|
|
||||||
if #available(iOS 15.0, *) {
|
|
||||||
visibilityBarButtonItem.isSelected = !visibilityBarButtonItem.isSelected
|
|
||||||
showStatusesAutomatically = visibilityBarButtonItem.isSelected
|
|
||||||
} else {
|
|
||||||
showStatusesAutomatically = !showStatusesAutomatically
|
showStatusesAutomatically = !showStatusesAutomatically
|
||||||
}
|
|
||||||
#else
|
|
||||||
showStatusesAutomatically = !showStatusesAutomatically
|
|
||||||
#endif
|
|
||||||
|
|
||||||
let snapshot = dataSource.snapshot()
|
let snapshot = dataSource.snapshot()
|
||||||
for case let .status(id: _, state: state) in snapshot.itemIdentifiers where state.collapsible == true {
|
for case let .status(id: _, state: state) in snapshot.itemIdentifiers where state.collapsible == true {
|
||||||
|
@ -353,12 +344,16 @@ class ConversationTableViewController: EnhancedTableViewController {
|
||||||
tableView.beginUpdates()
|
tableView.beginUpdates()
|
||||||
tableView.endUpdates()
|
tableView.endUpdates()
|
||||||
|
|
||||||
|
if #available(iOS 15.0, *) {
|
||||||
|
visibilityBarButtonItem.isSelected = showStatusesAutomatically
|
||||||
|
} else {
|
||||||
if showStatusesAutomatically {
|
if showStatusesAutomatically {
|
||||||
visibilityBarButtonItem.image = ConversationTableViewController.hidePostsImage
|
visibilityBarButtonItem.image = ConversationTableViewController.hidePostsImage
|
||||||
} else {
|
} else {
|
||||||
visibilityBarButtonItem.image = ConversationTableViewController.showPostsImage
|
visibilityBarButtonItem.image = ConversationTableViewController.showPostsImage
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -247,7 +247,6 @@ extension MenuPreviewProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
private func addOpenInNewWindow(actions: inout [UIAction], activity: @escaping @autoclosure () -> NSUserActivity) {
|
private func addOpenInNewWindow(actions: inout [UIAction], activity: @escaping @autoclosure () -> NSUserActivity) {
|
||||||
#if SDK_IOS_15
|
|
||||||
if #available(iOS 15.0, *) {
|
if #available(iOS 15.0, *) {
|
||||||
let options = UIWindowScene.ActivationRequestOptions()
|
let options = UIWindowScene.ActivationRequestOptions()
|
||||||
options.preferredPresentationStyle = .automatic
|
options.preferredPresentationStyle = .automatic
|
||||||
|
@ -259,13 +258,6 @@ extension MenuPreviewProvider {
|
||||||
UIApplication.shared.requestSceneSessionActivation(nil, userActivity: activity(), options: nil, errorHandler: nil)
|
UIApplication.shared.requestSceneSessionActivation(nil, userActivity: activity(), options: nil, errorHandler: nil)
|
||||||
}))
|
}))
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
if UIDevice.current.userInterfaceIdiom == .pad || UIDevice.current.userInterfaceIdiom == .mac {
|
|
||||||
actions.append(createAction(identifier: "new_window", title: "Open in New Window", systemImageName: "rectangle.badge.plus", handler: { (_) in
|
|
||||||
UIApplication.shared.requestSceneSessionActivation(nil, userActivity: activity(), options: nil, errorHandler: nil)
|
|
||||||
}))
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue