events: fix tab-created (trigger parent directly)
This commit is contained in:
parent
8c194be517
commit
3c83a35c37
2 changed files with 1 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ var updateDom = function(widget, options = {}) {
|
|||
|
||||
widget.container.replaceWith(newWidget.container)
|
||||
|
||||
if (data.type == 'tab') newWidget.trigger('tab-created', [{widget: widget}])
|
||||
if (data.type == 'tab') newWidget.parent.trigger('tab-created', [{widget: widget}])
|
||||
|
||||
$('.editor-root').attr('data-widget', $('.root-container').attr('data-widget'))
|
||||
|
||||
|
|
|
|||
|
|
@ -80,7 +80,6 @@ module.exports = class Panel extends _widgets_base {
|
|||
})
|
||||
|
||||
this.on('tab-created', (e)=>{
|
||||
if (e.widget == this) return
|
||||
this.createNavigation()
|
||||
e.stopPropagation = true
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue