Open
Conversation
Owner
|
I'm not sure that the datagrid should listen to the sort event because if you bypass the datagrid to directly call sort on the collection, the rows sort order will be inconsistent with the sort icons displayed in the header. What do you think? |
Contributor
Author
|
OK, I'll try fixing also the header :-) I think updating the table when the collection is externally sorted is insteresting, as allows easier integration with other views manipulating the data in the collection. |
Owner
|
Ok, let me know how it goes 👍 |
…n's sort event. Listening to collection's sort event would require also to update datagrid's sorting, and maybe the sorter used to sort the collection is not one of datagrid's column sorter.
Contributor
Author
|
I didn't find a solution to the header, so at least I fixed the bug. I only checked with inMemory collection, but I suppose the other way worked already fine, as remote sorting resets the collection. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The table was not updated after collection sorting.
Maybe datagrid view should render after any of the collection events, but I
bind only to 'sort' to go one test each time :-)