You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
weakreference里的对象 有强引用存在时,gc不是一下就回收的
延迟不是个好方法,是为了防止卡按钮动画效果
在2017年04月1日 01:28,碰碰凉<notifications@github.com> 写道:
您好:
我的毕设打算做一款音乐播放器,最近在学习您的代码,我想请问下在remote Service中返回的IBinder的实现类中,为什么要使用WeakReference呢,还有在MusicPlayer中使用的是WeakHashMap,是担心内存问题么?假如GC执行了一次,他们岂不是就被回收掉了?这块没太想明白。
还有播放音乐MusicPlayer.playAll()时, handler.postDelayed(playMusic, 70);这里使用了一个70毫秒的延迟,我尝试过不延迟,也可以正常播放,请问这里是为什么
小弟愚昧,还望赐教!谢谢
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
您好:
小弟愚昧,还望赐教!谢谢
The text was updated successfully, but these errors were encountered: