Skip to content

Commit

Permalink
removed didFinish delegate method
Browse files Browse the repository at this point in the history
  • Loading branch information
sergiothinks2 committed Jan 31, 2025
1 parent 36c5125 commit 8976c62
Showing 1 changed file with 0 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,6 @@ class WKNavigationDelegateProxy: NSObject {
self.originalDelegate = originalDelegate
self.callback = callback
}

// 1. remove this first then have the client test
// Test this first on a test app!
// override func responds(to aSelector: Selector!) -> Bool {
// if super.responds(to: aSelector) {
// return true
// } else if let originalDelegate = originalDelegate, originalDelegate.responds(to: aSelector) {
// return true
// }
// return false
// }

// webview with delegate method that implements this methods
// webview capture service
// are they using third party web view libraries


override func forwardingTarget(for aSelector: Selector!) -> Any? {
if super.responds(to: aSelector) {
Expand Down Expand Up @@ -85,15 +69,5 @@ extension WKNavigationDelegateProxy: WKNavigationDelegate {
// call original
originalDelegate?.webView?(webView, didFail: navigation, withError: error)
}

func webView(_ webView: WKWebView,
didFinish navigation: WKNavigation!
) {
// Capture navigation event
callback?(webView.url, nil)

// Call original delegate's implementation if available
originalDelegate?.webView?(webView, didFinish: navigation)
}
}
#endif

0 comments on commit 8976c62

Please sign in to comment.