From fa50b52c39fd4a47c33717e3098399516f65c011 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 17 Mar 2017 18:41:38 +0100 Subject: [PATCH] theme - restore tabs flicker protection --- src/vs/workbench/browser/parts/editor/media/tabstitle.css | 8 ++++++-- src/vs/workbench/browser/parts/editor/tabsTitleControl.ts | 4 ++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/media/tabstitle.css b/src/vs/workbench/browser/parts/editor/media/tabstitle.css index 4b0febe1ecf3f..eee238dead691 100644 --- a/src/vs/workbench/browser/parts/editor/media/tabstitle.css +++ b/src/vs/workbench/browser/parts/editor/media/tabstitle.css @@ -5,7 +5,11 @@ /* Title Container */ -.hc-black .monaco-workbench > .part.editor > .content > .one-editor-silo > .container > .title.tabs.shows-tabs { +.monaco-workbench > .part.editor > .content > .one-editor-silo > .container > .title.empty { + background: inherit !important; /* prevents some ugly flickering when opening first tab */ +} + +.hc-black .monaco-workbench > .part.editor > .content > .one-editor-silo > .container > .title.tabs { border-bottom: 1px solid; } @@ -182,7 +186,7 @@ /* TODO@theme */ -.hc-black .monaco-workbench > .part.editor > .content > .one-editor-silo > .container > .title.tabs.shows-tabs { +.hc-black .monaco-workbench > .part.editor > .content > .one-editor-silo > .container > .title.tabs { border-bottom-color: #6FC3DF; } diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 69aeb83529c6c..c7f7a8be5cba9 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -351,7 +351,7 @@ export class TabsTitleControl extends TitleControl { // Handle Tabs this.handleTabs(group.count); - DOM.addClass(this.titleContainer, 'shows-tabs'); + DOM.removeClass(this.titleContainer, 'empty'); // Update Tabs this.doUpdate(); @@ -363,7 +363,7 @@ export class TabsTitleControl extends TitleControl { this.tabDisposeables = dispose(this.tabDisposeables); this.editorLabels = []; - DOM.removeClass(this.titleContainer, 'shows-tabs'); + DOM.addClass(this.titleContainer, 'empty'); } private handleTabs(tabsNeeded: number): void {