0
我在我的ViewController
添加GIDSignInDelegate
和補充功能:視圖控制器不符合協議「GIDSignInDelegate」
sign(_ signIn: GIDSignIn!, didSignInFor user: GIDGoogleUser!, withError error: Error!)
但Xcode中還在抱怨協議。見screenshot
我在我的ViewController
添加GIDSignInDelegate
和補充功能:視圖控制器不符合協議「GIDSignInDelegate」
sign(_ signIn: GIDSignIn!, didSignInFor user: GIDGoogleUser!, withError error: Error!)
但Xcode中還在抱怨協議。見screenshot
在https://developers.google.com/identity/sign-in/ios/api/protocol_g_i_d_sign_in_delegate-p該文檔描述了兩種方法。您還需要signIn:didDisconnectWithUser:withError:
如果您輸入func didDisconnect
Xcode應爲您填寫。
Tks Nate。我已經添加了。我更新了截圖。 –
@YgorYuri如果您轉到問題導航器並單擊錯誤旁邊的向下箭頭,它會顯示缺少的內容。它在那裏說什麼? –
Xcode讓我選擇添加我已經添加的func。看看我的答案更新 –