Fixing issue around removing listeners

Previous fix was erroneous as all listeners were removed, not the correctly scoped ones. This fix properly maintains the reference to the listener callback, so that when the cue point is removed, it removes correctly.