I am implementing a "Tabbet App" and I need a "Tab" to open a URL in Safari (new window not in the same viewcontroller)
Currently for example in the viewcontroller of Tab4 (Tab4ViewControllerView.swif) I have added the following code:
guard let url = URL(string: "https://google.com") else {
return //be safe
}
if #available(iOS 10.0, *) {
UIApplication.shared.open(url, options: [:], completionHandler: nil)
} else {
UIApplication.shared.openURL(url)
}
It works but when I return from Safari to the application, Tab4 is selected and since it does not contain anything it looks white.
I need to click on Tab4 to open Safari but it should not be selected (you must keep selecting the previous tab.)
In the example of the image: I am currently in Tab1 and pressing Tab4 should open Safari but keeping selected Tab1


