WKWebview在目标c中的委托方法

问题描述 投票:0回答:1

更新我的代码,从UIWebView到WKWebview,但在我的委托方法上出现了这个错误。

Nullability specifier 'nonnull' conflicts with existing specifier 'null_unspecified'

这是我的代码,显示这个错误的 navigation

- (void)webView:(WKWebView *)webView didCommitNavigation:(WKNavigation *)navigation{
  // Show & animate the activity indicator.
  _webView.spinner.hidden = NO;
  [_webView.spinner startAnimating];
}
objective-c xcode wkwebview wkwebviewconfiguration
1个回答
1
投票

看起来你在某个地方重新声明了这个委托方法,可能是在委托头中,所以找到它并使用原来的方法。

- (void)webView:(WKWebView *)webView didCommitNavigation:(null_unspecified WKNavigation *)navigation;
© www.soinside.com 2019 - 2024. All rights reserved.