Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BindableCollection Insert issue #5

Closed
TheProxyRE opened this issue Dec 21, 2018 · 1 comment
Closed

BindableCollection Insert issue #5

TheProxyRE opened this issue Dec 21, 2018 · 1 comment
Labels
bug Something isn't working

Comments

@TheProxyRE
Copy link

In RootViewModel.cs on AddDownload method

Downloads.Insert(index, download); line fails on large playlists
quick fix is just to always insert on 0 but i doubt that is best solution

here is example large playlist if you want to play with it a bit: https://www.youtube.com/playlist?list=PL5ezn3MwwSNFNxyCiWYpJ0bx905ui-x-r

@Tyrrrz Tyrrrz added the bug Something isn't working label Dec 21, 2018
@Tyrrrz
Copy link
Owner

Tyrrrz commented Dec 21, 2018

This approach was made so that multiple videos are added to the top with order preserved. It looks like index becomes out of bounds because there are 2 videos with identical autogenerated file paths, so one of the AddDownload calls overwrites a download instead of adding a new one, which causes the index to become invalid.

I will have to look into it...

@Tyrrrz Tyrrrz closed this as completed in 4c2fb45 Dec 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants