Feature #2801: As a modeller, I want that model browser correctly shows the element that is currently selected
Fix graph explorer selection to work when selected data is removed
|Assignee:||Tuukka Lehtonen||% Done:|
|Category:||-||Estimated time:||0.00 hour|
|Target version:||-||Spent time:||5.00 hours|
The selection mechanism in model browser does not work always correctly. I noticed this by creating few new models (File->New model) and then trying to delete them by keyboard delete button. The first one was deleted correctly. The selection seemed to be on the second model which was highlighted but the property view still displayed the properties of the old (deleted) model. Only after moving by arrow keys (one down) the property view was updated to show the correct properties for the selected model and the delete worked as expected.
Fixed GraphExplorerImpl to keep its ISelectionProvider's selection up-to-date in cases where data used for selected tree items is removed and the same tree item is reused for different data.
Still some more fixes for cases where deleted explorer nodes would selection/post-selection listeners to go out of sync. Fixed by unifying the selection reset code between cases where tree item selection changes and where logical selection changes but tree selection does not.