robo-cjk
robo-cjk copied to clipboard
Rename DC or AE glyph should propagate to all parent glyphs
As discussed during the meeting today, this isn't easy.
In my view, this is what should happen, when a DC or AE gets renamed:
- Check which parent glyphs use the DC/AE being renamed
- Lock all involved glyphs. If locking fails: bail out, don't rename (report who owns the locks)
- Check that the set calculated in step 1 is still the same. If no: unlock and bail out
- Rename the DC/AE, and fix the references in all the parent glyphs
- Unlock all
Should this be done at the RoboCJK client level, or is it a task that can be delegated to the server? The latter would be much better for performance.
My assuption: renaming DCs or AEs should be rare, therefore it's an acceptable tradeoff that the procedure to do it is a little slow or cumbersome.
Cc @fabiocaccamo @GaetanBaehr @JeremieHornus @jbmorizot
Also relates to #23: renaming should be impossible to do accidentally, and should require an obnoxious comfirmation dialog.