Post

Replies

Boosts

Views

Activity

Does load(_ request: URLRequest) on WKWebView ever return nil?
I can't find a situation where the load(_ request: URLRequest) method of WKWebView would ever return nil, though the return object is WKNavigation? I've tested on a playground with URLs generated from all kinds of strings and can't make it return nil. I also ran without Internet connection, but I still get a WKNavigation returned. If it never returns nil, I can be sure that any loading failure can be picked up in the navigation delegate methods, which subsequently simplifies the rest of my code. Does it ever return nil? If so, under what conditions? Many thanks in advance
Topic: Safari & Web SubTopic: General Tags:
0
0
404
Apr ’23
Navigation bar not hiding in iOS15
I have SwiftUI view set as the root view of a UIHostingController. This root view is then added as a subview of the view of a UIViewController. The UIViewController is a property on a parent view controller that deals with a UINavigationController. The view in the body of the SwiftUI view, ends with: .navigationBarHidden(someBooleanProperty) The intention is that when someBooleanProperty switches between true and false, the UIKit navigation bar is shown and hidden accordingly. This works perfectly on devices running iOS14, but not with iOS15. Any ideas why? I've searched the internet for answers, but to no avail.
0
0
803
May ’22
Adapting orthogonal scrolling behaviour
I have a compositional layout with one section that scrolls orthogonally. For the groups that are not at the ends of the scroll, I want them to follow groupPagingCentered behaviour, so I set the orthogonal scrolling behaviour accordingly. However, I want the group at the beginning of the scroll to be left justified (groupPaging behaviour) and the group at the end of the scroll to be right justfied, without changing the separation between groups. How can I achieve this? (need to support iOS 13)
Topic: UI Frameworks SubTopic: UIKit Tags:
0
0
651
Jul ’21
View controller inside collection view cell
I have a collection view on a view controller. When I dequeue a cell, it is configured with several views, one of which is the view of another view controller. This sub-view-controller is reinitialised every time the cell is configured. Should I, or should I not, add this sub-view-controller as a child of the parent view controller that owns the collection view?
Topic: UI Frameworks SubTopic: UIKit Tags:
1
0
1.4k
Jun ’21
App Store rejection - prefetch ODR not loading in iOS
This app has gone through many small updates without issue and has now been rejected by App Store review, saying it won't load the initial prefetch ODR on startup. This has never been a problem, except at the very beginning, when it turned out to be an Apple bug issue for TestFlight, but not in review for the App Store. Any possible glitches or changes with iOS 14 that might cause this? Simulator works just fine, but no actual iPad device to test with.
5
0
1.4k
Sep ’20