Bind handleExpansionToggleDblClickEvent in TreeWidget#9877
Bind handleExpansionToggleDblClickEvent in TreeWidget#9877colin-grant-work merged 2 commits intoeclipse-theia:masterfrom scottaxcell:9876-unbound-tree-expansion-on-click-handler
Conversation
msujew
left a comment
There was a problem hiding this comment.
Thank you for your contribution @scottaxcell, that looks like it does the job. I have one issue with this though:
This is a breaking change, as it does not allow to override handleExpansionToggleDblClickEvent as a method in subclasses of TreeWidget anymore. You would instead have to override doHandleExpansionToggleDblClickEvent.
I would usually recommend to instead simply replace its calling site with event => this.handleExpansionToggleDblClickEvent(event) in line 575. However, your approach keeps everything in line with other methods like toggle which is implemented in the same way. So I don't really care which way you go, but going with your current one requires you to describe your breaking changes in the changelog.
|
@msujew thanks for the feedback. In keeping with the current convention, I'll leave the change as is and update the changelog. |
msujew
left a comment
There was a problem hiding this comment.
I can confirm that the issue exists on master and is nicely addressed by this change:
- Double clicking a toggle node on
masterleads to an error stating:this is undefined. - Double clicking a toggle node with the changes in place correctly stops the propagation of the event.
|
@vince-fugnitto, would you be willing to restart the tests for this PR? I don't believe this code is responsible for the failure, but always nice to have all green. |
…9877) Ensure `handleExpansionToggleDblClickEvent` correctly bound in TreeWidget Co-authored-by: Scott Axcell <scott.axcell@xilinx.com>
What it does
Fixes #9876 .
How to test
See #9876 steps to reproduce.
Review checklist
Reminder for reviewers
Signed-off-by: Scott Axcell scott.axcell@xilinx.com