Closed wimwu closed 5 years ago
我这边没有检测到哦
看了下源码中toast的创建 ToastUtils.sToast = ToastUtils.ToastFactory.makeToast(Utils.getTopActivityOrApp(), text, duration); sToast是静态变量,toast的上下文是顶部的activity,导致关闭时被持有不能释放
同样发现泄露
1.22.1修复了吗
下个版本吧,sToast 只是暂时泄漏了,之后会回收的应该是。
1.22.1还存在问题
iToast = ToastFactory.makeToast(Utils.getTopActivityOrApp(), text, duration);
应该不是短暂的泄漏
我也不知道啥时候居然把
iToast = ToastFactory.makeToast(Utils.getApp(), text, duration);
改成了
iToast = ToastFactory.makeToast(Utils.getTopActivityOrApp(), text, duration);
新版 1.22.2 内存泄漏我已经修复啦,不论是否有通知权限都不会泄漏了。
1.24.3 还是存在内存泄漏
Describe the bug
A clear and concise description of what the bug is.
The code of bug
看了@254的issues,问题应该还在,没有使用自定义布局,就简单的ToastUtils.showShort(int stringRes)调用,使用了 leaks检测工具,很容易出现
Please delete the current line and the followings.
Thank you for supporting AndroidUtilCode.