Pagescene: identify if changes made this session
A bug:
- Annotate a paper.
- close annotator
- open to reannotator
- but don't change anything
- try to close annotator
In step 5 you will get a message like "There are annotations, are you sure want to close?" which isn't quite right b/c there are annotations but they are saved. The state is "clean". So instead we should just close. This doesn't seem too serious but is annoying for some UI experiments I'm trying.
This MR tries to fix this bug by adding a "is_dirty()" concept to PageScene . Its feels like a bit of hack, but does obey the campsite rule: added a Mixin class to remove some itemChanged
code duplication.
I found out after I did this that QUndoStack has a clean
concept which could probably could be used here to remove the perfectly solves this problem._dirty
instance variable. Maybe later: a TODO has been left