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

Correctly display graphs when sorting is enabled #30

Merged
merged 3 commits into from
Apr 7, 2024

Conversation

jfernandez
Copy link
Contributor

@jfernandez jfernandez commented Apr 7, 2024

Previously we would use the index of the items collection to find the selected program. This worked until we added sorting, and now we don't get graphs if the selected program's index changes.

I took the opportunity to refactor a few things to use less shared state/locks and also fix this issue. We will now store a copy of the selected program the moment a user enters the Graph mode. This means we will no longer need to share the table state with the background thread.

cc @tyrone-wu

@jfernandez
Copy link
Contributor Author

This change will also fix the deadlock found in #17

@jfernandez jfernandez merged commit 152eb66 into main Apr 7, 2024
1 check passed
@jfernandez jfernandez deleted the fix-sorted-selected branch April 7, 2024 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant