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

Added the functionnality to be able to reparent items #356

Open
wants to merge 32 commits into
base: master
Choose a base branch
from

Conversation

GuillaumeFromage
Copy link

Hi,

I've did the necessary changes to get the ability to reParent items in the hierarchy.
This is mostly UI work, as the git backend changes were minor. Quite some care was put into making sure that if you move a tag in the tag panel, it stayed coherent in the annotation panel. A ton of testing was made, making item roots, adding them subitems, etc.

It wasn't necessary to reparent each TagInstance and TagReference, as the tags are referred in the shape "TAGSET/TAG" in the annotation file.

Same thing goes for the deletion of tags. That would be important if moved tags in between tagsets, but it isn't necessary as the system don't freak out seeing items out of place, as long as they aren't missing. I was able to move tagsets around => sync => open on another user multiple times without issues.

This is a ton of code, so there might be new bugs introduced, but I tested quite a lot. I kept some part of a time budget to fix upcoming bugs.

…st of selected tags

I take baby steps. I need to do this if I want the addSubtagDialog to show a box containing
the currently selected tag in TagsView object, which is currently not sent down to the
dialog.
More baby steps. I still need to fix the ListBox items shown, but there is a listbox which
allow multiple select, and the listbox feeds on TagDefinition. Its getting somewhere.
This is still broken, it should only show the current tagset we're working on,
but that is from a regression introduced in previous baby step.
The whole code seems to be designed around the fact that you can select
multiple parents, even though the tag selection is singleSelect. It would
be straightforward to convert this to a ComboBox. When you select multiple
parents, a copy of the tag is added into each parent.

This feature is not really requested, but a) its not completely useless,
b) and the whole edit subtag with tagset selection and parent tag
selection actually need most of that code, might has well try to develop
and test it first in a separate block.
…working

Only a) making it look nice, b) and having a listener if there is multiple
tagsets is left.
When you edit a tag, by default it shows its parent in its own tagset. If multiple tagsets are selected, you can navigate among them, and the parent choice select box shows the potential list of parent from that tagset.
I had to make sure that there were only one tag selected
… functions that sends down the info to the deepest layers
… a note that the old def was removed

Also optimized a bit
… the tree) and fixed a bug that crashed the backend
It would have been an easy feature to add, but I won't have time to finish it
…the UI

This is to prevent the tags from being separated from their parents
@maltem-za
Copy link
Member

Hi @GuillaumeFromage, just back from my leave. I'll look at this and your other PRs as soon as I can.

@maltem-za
Copy link
Member

Ref. #352

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.

2 participants