only one update

This commit is contained in:
zadam 2020-03-07 15:01:48 +01:00
parent 8513e0201c
commit 62da383623
2 changed files with 6 additions and 2 deletions

View File

@ -111,6 +111,12 @@ export default class NoteDetailWidget extends TabAwareWidget {
await typeWidget.handleEvent('setTabContext', {tabContext: this.tabContext});
// this is happening in update() so note has been already set and we need to reflect this
await typeWidget.handleEvent('tabNoteSwitched', {
tabContext: this.tabContext,
notePath: this.tabContext.notePath
});
this.child(typeWidget);
}

View File

@ -80,8 +80,6 @@ export default class TabAwareWidget extends BasicWidget {
setTabContextEvent({tabContext}) {
/** @var {TabContext} */
this.tabContext = tabContext;
this.refresh();
}
async noteTypeMimeChangedEvent({noteId}) {