Skip to content

Commit

Permalink
Don't paste to active editor when a tab is closed by mouse wheel click
Browse files Browse the repository at this point in the history
Signed-off-by: Dmitry Sharshakov <d3dx12.xx@gmail.com>
  • Loading branch information
dsseng authored and paul-marechal committed Apr 15, 2020
1 parent 46f5a08 commit e2dfc1a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/core/src/browser/shell/tab-bars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,11 @@ export class TabBarRenderer extends TabBar.Renderer {
{
key, className, id, title: title.caption, style, dataset,
oncontextmenu: this.handleContextMenuEvent,
ondblclick: this.handleDblClickEvent
ondblclick: this.handleDblClickEvent,
onauxclick: (e: MouseEvent) => {
// If user closes the tab using mouse wheel, nothing should be pasted to an active editor
e.preventDefault();
}
},
h.div(
{ className: 'theia-tab-icon-label' },
Expand Down

0 comments on commit e2dfc1a

Please sign in to comment.