[IMPROVEMENT] added configurable limit to rendering of current playlist. #20
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Previously there wasn't any limit which caused browsers to freeze while trying to render ten thousands of tracks. Especially the javascript event-listeners were not able to handle such a big DOM besides the fact that there is no benefit at all to display that much stuff.
In case the total playlist length is shorter than the configured limit there is no visually change of O!MPD at all. Otherwise i have added a message like
(showing 943-1443 of 23515 Tracks)
on top of the playlistTODO: a pagination would make sense but its not that important because the currently played track should always be visible within the rendered portion of tracks