Skip to content
This repository was archived by the owner on Sep 19, 2024. It is now read-only.

Commit 158aa46

Browse files
committed
Amendment to UIKit fix
1 parent 92b5fde commit 158aa46

File tree

2 files changed

+12
-14
lines changed

2 files changed

+12
-14
lines changed

Library/Core/NibResource.swift

-14
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,3 @@ public protocol NibResource {
1717
/// Name of the nib file on disk
1818
var name: String { get }
1919
}
20-
21-
public extension NibResource {
22-
/**
23-
Instantiate the nib to get the top-level object from this nib
24-
25-
- parameter ownerOrNil: The owner, if the owner parameter is nil, connections to File's Owner are not permitted.
26-
- parameter options: Options are identical to the options specified with -[NSBundle loadNibNamed:owner:options:]
27-
28-
- returns: An array containing the top-level objects from the NIB
29-
*/
30-
public func instantiateWithOwner(ownerOrNil: AnyObject?, options optionsOrNil: [NSObject : AnyObject]?) -> [AnyObject] {
31-
return initialize().instantiateWithOwner(ownerOrNil, options: optionsOrNil)
32-
}
33-
}

Library/UIKit/NibResource+UIKit.swift

+12
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,16 @@ public extension NibResource {
1717
public func initialize() -> UINib {
1818
return UINib.init(nibName: name, bundle: bundle)
1919
}
20+
21+
/**
22+
Instantiate the nib to get the top-level object from this nib
23+
24+
- parameter ownerOrNil: The owner, if the owner parameter is nil, connections to File's Owner are not permitted.
25+
- parameter options: Options are identical to the options specified with -[NSBundle loadNibNamed:owner:options:]
26+
27+
- returns: An array containing the top-level objects from the NIB
28+
*/
29+
public func instantiateWithOwner(ownerOrNil: AnyObject?, options optionsOrNil: [NSObject : AnyObject]?) -> [AnyObject] {
30+
return initialize().instantiateWithOwner(ownerOrNil, options: optionsOrNil)
31+
}
2032
}

0 commit comments

Comments
 (0)