Skip to content

Commit

Permalink
fixes #340-error dragging tabset into empty tabset
Browse files Browse the repository at this point in the history
  • Loading branch information
nealus committed Oct 14, 2022
1 parent 418f05a commit 55fa509
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/model/TabSetNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -422,6 +422,9 @@ export class TabSetNode extends Node implements IDraggable, IDropTarget {
// console.log("added child at : " + insertPos);
insertPos++;
}
if (this.getSelected() === -1 && this._children.length > 0) {
this._setSelected(0);
}
}
this._model._setActiveTabset(this);
} else {
Expand Down

0 comments on commit 55fa509

Please sign in to comment.