閉じずに残ってしまうメニューなどの修正 (#5496)

* Fix: ページ移動等してもメニュー等が閉じずに残ってしまう

* Fix: ページ移動してもメディアビューワーが残ってしまう
This commit is contained in:
MeiMei 2019-10-09 21:42:23 +09:00 committed by syuilo
parent d17c6adba4
commit a85f6edd8a
6 changed files with 31 additions and 7 deletions

View file

@ -53,10 +53,13 @@ export default Vue.extend({
start = videoTag.currentTime
videoTag.pause()
}
this.$root.new(MkMediaVideoDialog, {
const viewer = this.$root.new(MkMediaVideoDialog, {
video: this.video,
start,
})
});
this.$once('hook:beforeDestroy', () => {
viewer.close();
});
}
}
})

View file

@ -106,10 +106,13 @@ export default Vue.extend({
},
menu() {
this.$root.new(XUserMenu, {
const w = this.$root.new(XUserMenu, {
source: this.$refs.menu,
user: this.user
});
this.$once('hook:beforeDestroy', () => {
w.destroyDom();
});
}
}
});