Commit 05e13281 authored by Soomin Lee's avatar Soomin Lee

VideoModel: Listen to media deletion

parent 21a4e549
......@@ -59,6 +59,16 @@ extension VideoModel: MediaLibraryObserver {
videos.forEach({ append($0) })
updateView?()
}
func medialibrary(_ medialibrary: VLCMediaLibraryManager, didDeleteMediaWithIds ids: [NSNumber]) {
files = files.filter() {
for id in ids where $0.identifier() == id.int64Value {
return false
}
return true
}
updateView?()
}
}
extension VLCMLMedia {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment