feat(annotation): added keybinds for iterating through annotation list, also pins and jumps to each annotation #624
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.
Our plan is to have keybinds to iterate through any visible list for the currently selected layer.
I couldn't find any way to access tab instances. Before attempting to make the changes necessary to access, for example, the tabs for a given layer. I tried two alternative approaches. One uses element.dispatchEvent for a custom event. The other adds a similar event model to the UserLayerClass (
registerLayerEvent
anddispatchLayerEvent
).Currently segmentation lists don't have the same ability to select an annotation other than the pinned segment. I am going to try to get that working as well.
The current issue I have with the layer event model is that I need a way identify if the tab is the primary tab of the currently selected layer. I left some commented out code like
this.layer.panels.panels[0].selectedTab.value === "annotations"
. Otherwise it will iterate every visible list.