android - AccountAuthenticatorActivity 上的 getSupportFragmentManager

标签 android android-alertdialog android-support-library accountmanager

如何将 getSupportFragmentManager() 传递给 AccountAuthenticatorActivity 中的外部库?

我需要使用 android-styled-dialogs 添加自定义对话框:https://github.com/inmite/android-styled-dialogs

最佳答案

  1. AccountAuthenticatorActivity并将其放入您的项目中。

  2. 代替 AccountAuthenticatorActivity 扩展 Activity 放置 AccountAuthenticatorActivity 扩展 FragmentActivity

  3. 使用新的 AccountAuthenticatorActivity 扩展您的类并使用 getSupportFragmentManager()

关于android - AccountAuthenticatorActivity 上的 getSupportFragmentManager,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19126290/

相关文章:

java - 使用 finishActivity() 时的请求代码是什么

Android 不在 OnActivityResult 中显示对话框

android - 样式工具栏无法使用 AppCompat

android - 保留 fragment 供以后显示的最佳实践

android - SearchView getActionView 返回 null

安卓 : How to display more than one Marquee simultaneously (focus for two marquees)

android - 在Google Play商店中上传失败

android - requestLocationUpdates 在位置变化实际上增加了一次时调用了很多次

Android 测试在 Activity 中显示 alertDialog

android - AlertDialog 的项目未显示