简体   繁体   English

Facebook iOS SDK - 用于登录的UIWebView对话框 - 用户如何手动取消?

[英]Facebook iOS SDK - UIWebView dialog for login - how can user manually cancel?

I'm having a problem here. 我在这里遇到了问题。 I've modified a portion of the source code to prevent my app from launching the Facebook app or Safari for authentication. 我修改了部分源代码,以防止我的应用程序启动Facebook应用程序或Safari进行身份验证。 Instead, a UIWebView will be displayed as an overlay on my app. 相反,UIWebView将作为覆盖显示在我的应用程序上。

However, in the dialog. 但是,在对话框中。 I noticed there isn't any CANCEL button. 我注意到没有任何“取消”按钮。 Which makes me wonder what happens if the user decides not to login. 这让我想知道如果用户决定不登录会发生什么。

I had forgotten to copy the FBDialog.bundle over to my project! 我忘了将FBDialog.bundle复制到我的项目中! ahh! 啊!

Are you using FB graph API for facebook login.? 您是否正在使用FB graph API进行Facebook登录? If yes, Then the view that you see for login is programmatically created. 如果是,则以编程方式创建您看到的用于登录的视图。 Look into the FBGraph.m for its implementation. 查看FBGraph.m的实现。 There you can add a cancel button and add your cancel logic there. 在那里你可以添加一个取消按钮并在那里添加你的取消逻辑。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM