synchronous events, updating title works fully

This commit is contained in:
zadam
2020-01-19 20:18:02 +01:00
parent bd8e5f255b
commit 1098d75ce0
8 changed files with 112 additions and 15 deletions

View File

@@ -8,8 +8,16 @@ export default class TabAwareWidget extends BasicWidget {
this.noteSwitched();
}
isTab(tabId) {
return this.tabContext && this.tabContext.tabId === tabId;
}
isNote(noteId) {
return this.tabContext && this.tabContext.note && this.tabContext.note.noteId === noteId;
}
tabNoteSwitchedListener({tabId}) {
if (this.tabContext && tabId === this.tabContext.tabId) {
if (this.isTab(tabId)) {
this.noteSwitched();
}
}