We need to dispose() our clip buffers on the main thread.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4095 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -132,9 +132,13 @@ public class SoundManager
|
|||||||
_clips.setRemovalObserver(
|
_clips.setRemovalObserver(
|
||||||
new LRUHashMap.RemovalObserver<Comparable,ClipBuffer>() {
|
new LRUHashMap.RemovalObserver<Comparable,ClipBuffer>() {
|
||||||
public void removedFromMap (LRUHashMap<Comparable,ClipBuffer> map,
|
public void removedFromMap (LRUHashMap<Comparable,ClipBuffer> map,
|
||||||
ClipBuffer item) {
|
final ClipBuffer item) {
|
||||||
Log.debug("Flushing " + item.getKey());
|
_rqueue.postRunnable(new Runnable() {
|
||||||
item.dispose();
|
public void run () {
|
||||||
|
Log.debug("Flushing " + item.getKey());
|
||||||
|
item.dispose();
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user