Skip to content

Commit

Permalink
Merge pull request #91 from vtourraine/fix-xcode-13
Browse files Browse the repository at this point in the history
Fix Xcode 13 compatibility
  • Loading branch information
vtourraine authored Sep 17, 2021
2 parents 081cead + 7b3c48c commit 26f4b9c
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 10 deletions.
4 changes: 2 additions & 2 deletions AcknowList.podspec.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "AcknowList",
"version": "2.0.1",
"version": "2.0.2",
"summary": "Ready to use “Acknowledgements”/“Licenses” view controller for CocoaPods.",
"homepage": "https://github.com/vtourraine/AcknowList",
"license": {
Expand All @@ -12,7 +12,7 @@
},
"source": {
"git": "https://github.com/vtourraine/AcknowList.git",
"tag": "2.0.1"
"tag": "2.0.2"
},
"source_files": "Sources/AcknowList/*.swift",
"resource_bundles": {
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
- Add SwiftUI interface (supports iOS/tvOS/watchOS/macOS)


## 2.0.2 (17 September 2021)

- Update `AcknowListViewController` to remove Objective-C compatibility, fixing Xcode 13 support


## 2.0.1 (26 April 2021)

- Update `AcknowListViewController` to make initializers available with Objective-C
Expand Down
12 changes: 7 additions & 5 deletions Examples/AcknowExampleManual/AcknowExample/ObjCViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,14 @@
@implementation ObjCViewController

- (void)presentAcknowListViewController {
NSString *path = @"";
AcknowListViewController *viewController = [[AcknowListViewController alloc] initWithPlistPath:path style:UITableViewStylePlain];
viewController.headerText = @"...";
viewController.footerText = @"...";
// Objective-C compatibility has been disabled, see: https://github.com/vtourraine/AcknowList/issues/89
//
// NSString *path = @"";
// AcknowListViewController *viewController = [[AcknowListViewController alloc] initWithPlistPath:path style:UITableViewStylePlain];
// viewController.headerText = @"...";
// viewController.footerText = @"...";

[self presentViewController:viewController animated:YES completion:nil];
// [self presentViewController:viewController animated:YES completion:nil];
}

@end
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ let package = Package(
name: "AcknowList",
defaultLocalization: "en",
platforms: [
.iOS(.v9), .tvOS(.v9), watchOS(.v7), macOS(.v10_15)
.iOS(.v9), .tvOS(.v9), .watchOS(.v7), .macOS(.v10_15)
],
products: [
.library(name: "AcknowList", targets: ["AcknowList"])
Expand Down
4 changes: 2 additions & 2 deletions Sources/AcknowList/AcknowListViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ open class AcknowListViewController: UITableViewController {

- returns: The new `AcknowListViewController` instance.
*/
@objc public convenience init(fileNamed fileName: String) {
public convenience init(fileNamed fileName: String) {
if let path = AcknowListViewController.acknowledgementsPlistPath(name: fileName) {
self.init(plistPath: path)
}
Expand All @@ -94,7 +94,7 @@ open class AcknowListViewController: UITableViewController {

- returns: The new `AcknowListViewController` instance.
*/
@objc public convenience init(plistPath: String, style: UITableView.Style = .grouped) {
public convenience init(plistPath: String, style: UITableView.Style = .grouped) {
self.init(acknowledgements: [], style: style)

load(from: plistPath)
Expand Down

0 comments on commit 26f4b9c

Please sign in to comment.