Skip to content

Commit ab517e3

Browse files
authored
Update UIHostingView (#703)
1 parent f04794e commit ab517e3

File tree

7 files changed

+471
-267
lines changed

7 files changed

+471
-267
lines changed

Sources/OpenSwiftUI/Integration/Hosting/UIKit/Controller/UIHostingController.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,10 @@ open class UIHostingController<Content>: UIViewController where Content : View {
9999
func _viewSafeAreaDidChange() {
100100
_openSwiftUIUnimplementedWarning()
101101
}
102+
103+
func didRender() {
104+
_openSwiftUIUnimplementedWarning()
105+
}
102106
}
103107

104108
@available(macOS, unavailable)

Sources/OpenSwiftUI/Integration/Hosting/UIKit/View/UIViewControllerProvider.swift renamed to Sources/OpenSwiftUI/Integration/Hosting/UIKit/Controller/UIViewControllerProvider.swift

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,17 @@
66
// Status: Complete
77

88
#if os(iOS) || os(visionOS)
9+
public import UIKit
10+
import COpenSwiftUI
911

10-
import UIKit
12+
// MARK: - UIViewControllerProvider
1113

12-
protocol UIViewControllerProvider: AnyObject {
14+
package protocol UIViewControllerProvider: AnyObject {
1315
var uiViewController: UIViewController? { get }
1416
}
1517

1618
extension UIViewControllerProvider {
17-
var containingViewController: UIViewController? {
19+
package var containingViewController: UIViewController? {
1820
if let uiViewController {
1921
return uiViewController
2022
} else if let view = self as? UIView {
@@ -24,5 +26,4 @@ extension UIViewControllerProvider {
2426
}
2527
}
2628
}
27-
2829
#endif

0 commit comments

Comments
 (0)