-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
重复设置显示布局时removeStatus问题 #35
Comments
不太清楚你问的什么问题 如果只是想自定义不同的空布局页面, 可以直接在 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
removeStatus方法只是将相关的StatusInfo信息删除,需要判断该StatusInfo引用的View是否已添加到statelayout,如果已添加需要调用removeView将其删除。
如下面代码,如果根据不同情况设置不同的空页面布局并显示空页面,在不同情况间切换时
设置emptyLayout会调用 removeStatus(EMPTY)将之前empty的StatusInfo从statusMap中删除,但原来的emptyView依然存在statelayout中
当调用showEmpty方法最终会showStatus执行
showStatus中这段代码是将上一状态的视图对象visibility设置为GONE,但由于之前重新设置emptyLayout时已将上一个empty的StatusInfo从statusMap删除,所以无法将原来的emptyView隐藏或删除
The text was updated successfully, but these errors were encountered: