Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cartfile
Original file line number Diff line number Diff line change
@@ -1 +1 @@
github "Swinject/Swinject" ~> 2.7.1
github "Swinject/Swinject" ~> 2.9.1
2 changes: 1 addition & 1 deletion Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1 +1 @@
github "Swinject/Swinject" "2.7.1"
github "Swinject/Swinject" "2.9.1"
4 changes: 2 additions & 2 deletions Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import PackageDescription
let package = Package(
name: "SwinjectStoryboard",
platforms: [
.macOS(.v10_10),
.iOS(.v9),
.tvOS(.v9),
.macOS(.v10_13),
.iOS(.v12),
.tvOS(.v12),
],
products: [
.library(name: "SwinjectStoryboard", targets: ["SwinjectStoryboard"]),
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ SwinjectStoryboard is an extension of Swinject to automatically inject dependenc

## Requirements

- iOS 8.0+ / Mac OS X 10.10+ / tvOS 9.0+
- iOS 12.0+ / Mac OS X 10.13+ / tvOS 12.0+
- Xcode 8+

## Installation
Expand Down
8 changes: 4 additions & 4 deletions Sources/ViewController+Swinject.swift
Original file line number Diff line number Diff line change
Expand Up @@ -61,19 +61,19 @@ extension NSWindowController: RegistrationNameAssociatable, InjectionVerifiable
#endif

extension NSObject {
fileprivate func getAssociatedString(key: UnsafeRawPointer) -> String? {
fileprivate func getAssociatedString(key: UnsafePointer<String>) -> String? {
return objc_getAssociatedObject(self, key) as? String
}

fileprivate func setAssociatedString(_ string: String?, key: UnsafeRawPointer) {
fileprivate func setAssociatedString(_ string: String?, key: UnsafePointer<String>) {
objc_setAssociatedObject(self, key, string, objc_AssociationPolicy.OBJC_ASSOCIATION_COPY)
}

fileprivate func getAssociatedBool(key: UnsafeRawPointer) -> Bool? {
fileprivate func getAssociatedBool(key: UnsafePointer<String>) -> Bool? {
return (objc_getAssociatedObject(self, key) as? NSNumber)?.boolValue
}

fileprivate func setAssociatedBool(_ bool: Bool, key: UnsafeRawPointer) {
fileprivate func setAssociatedBool(_ bool: Bool, key: UnsafePointer<String>) {
objc_setAssociatedObject(self, key, NSNumber(value: bool), objc_AssociationPolicy.OBJC_ASSOCIATION_COPY)
}
}
6 changes: 3 additions & 3 deletions SwinjectStoryboard.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ Pod::Spec.new do |s|
s.ios.source_files = core_files, objc_files, 'Sources/iOS-tvOS/*.{swift,h,m}'
s.osx.source_files = core_files, objc_files, 'Sources/OSX/*.{swift,h,m}'
s.tvos.source_files = core_files, objc_files, 'Sources/iOS-tvOS/*.{swift,h,m}'
s.ios.deployment_target = '8.0'
s.osx.deployment_target = '10.10'
s.tvos.deployment_target = '9.0'
s.ios.deployment_target = '12.0'
s.osx.deployment_target = '10.13'
s.tvos.deployment_target = '12.0'
s.dependency 'Swinject', '~> 2.7'
s.requires_arc = true
end