garkimasera / vlc-rs

Rust bindings for libVLC media framework.
MIT License
66 stars 18 forks source link

Add EventManager::detach method #14

Closed Richterrettich closed 3 years ago

Richterrettich commented 3 years ago

This gives the option to detach registered callbacks. Until now there was no way to clean up previous callbacks. In my case, I needed a callback to a high frequency event (MediaPlayerTimeChanged) for a limited amount of time. In order to achieve this, I made attach return the raw pointer which can be used to feed detach.