Android:是否保证Dialog的onCancel会在onDismiss之前调用?
通过测试我的实现,我能够确定在我的情况下,当注册 onCancelListener
和 onDismissListener
对话框回调时,onCancel
会先被调用onDismiss
。
然而,据我所知,Android API 对此并不清楚(再次),我只能假设这是一个 API 文档缺陷。有谁知道这是否在某个地方有正式记录?
By testing my implementation, I was able to determine that in my case, when both onCancelListener
and onDismissListener
Dialog callbacks are registered, onCancel
is called before onDismiss
.
However, as far as I can tell, the Android API is unclear (again) about this and I can only assume it's an API documentation defect. Does anyone know if this is officially documented somewhere?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
根据 Dialog.java 代码 , 是的。
According to the Dialog.java code, yes.