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
Remove internal event connection on SelectableEventedList #5339
Remove internal event connection on SelectableEventedList #5339
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Thanks for taking over. For info I think there were/are two reasons for not liking the code as it was, internal event connection and connection to a lambda. As I understand it internal event connection is just a bit harder to reason about and connecting to lambdas is a potential cause of the cleanup bugs we see in Qt tests sometimes
Looks like there's a real failure related to |
Codecov Report
@@ Coverage Diff @@
## main #5339 +/- ##
==========================================
- Coverage 89.10% 89.06% -0.04%
==========================================
Files 582 583 +1
Lines 49313 49336 +23
==========================================
+ Hits 43938 43939 +1
- Misses 5375 5397 +22
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
Fixed. Needed to call the super implementation of the deletion handler in |
* Add tests and fix with _process_delete_item * Also remove from selection in LayerList
* Add tests and fix with _process_delete_item * Also remove from selection in LayerList
* Add tests and fix with _process_delete_item * Also remove from selection in LayerList
* Add tests and fix with _process_delete_item * Also remove from selection in LayerList
* Add tests and fix with _process_delete_item * Also remove from selection in LayerList
Description
We try to avoid internal event connections, likely to avoid circular references. This PR removes such an internal event connection and also closes that particular TODO/FIXME.
It also adds tests to ensure we still get the desired behavior of removing a deleted item from the current selection.
Type of change
References
An alternative to #4534
How has this been tested?