Save selection to allow replay during undo

This commit is contained in:
Ian Gulliver
2019-07-12 01:05:04 +00:00
parent ed5c79c05d
commit 970c3faba9
7 changed files with 38 additions and 20 deletions

View File

@@ -1,6 +1,6 @@
class EditorHelp extends EditorEntryBase {
constructor() {
super();
constructor(id) {
super(id);
this.elem_.classList.add('help');
@@ -93,11 +93,12 @@ class EditorHelp extends EditorEntryBase {
serialize() {
return {
type: 'help',
id: this.getId(),
};
}
static unserialize(ser) {
return (new EditorHelp()).getElement();
return (new EditorHelp(ser.id)).getElement();
}
}