提交 2b73072d 编写于 作者: B Benjamin Pasero

theme - get rid of list.focusAndSelectionBackground

上级 f22230f4
......@@ -276,7 +276,6 @@
"button.hoverBackground": "#4A5C6B",
// "button.foreground": "",
"list.focusAndSelectionBackground": "#08286b",
"list.activeSelectionBackground": "#011B51",
// "list.activeSelectionForeground": "",
"list.focusBackground": "#08286b",
......
......@@ -5,7 +5,6 @@
// "focusBorder": "#00f9ff",
"dropdown.background": "#383852",
"list.activeSelectionBackground": "#303050",
"list.focusAndSelectionBackground": "#383852",
"list.inactiveSelectionBackground": "#303d45",
"list.hoverBackground": "#005070",
"list.dropBackground": "#505590",
......
......@@ -6,7 +6,6 @@
"dropdown.background": "#383852",
"list.activeSelectionBackground": "#303070",
"list.focusBackground": "#394770",
"list.focusAndSelectionBackground": "#383852",
"list.inactiveSelectionBackground": "#303d45",
"list.hoverBackground": "#005070",
"list.dropBackground": "#505590",
......
......@@ -458,7 +458,6 @@
"pickerGroup.border": "#749351",
"list.activeSelectionForeground": "#6c6c6c",
"list.focusBackground": "#CADEB9",
"list.focusAndSelectionBackground": "#A2B294",
"list.activeSelectionBackground": "#B6C8A7",
"editor.background": "#F5F5F5",
"editorWhitespace.foreground": "#AAAAAA",
......
......@@ -47,7 +47,6 @@
"list.activeSelectionBackground": "#700000",
"list.inactiveSelectionBackground": "#770000",
"list.focusBackground": "#660000",
"list.focusAndSelectionBackground": "#880000",
"list.highlightForeground": "#ff4444",
"notification.background": "#662222",
"pickerGroup.foreground": "#cc9999",
......
......@@ -316,7 +316,6 @@
"button.hoverBackground": "#2AA19844",
// "button.foreground": "",
"list.focusAndSelectionBackground": "#005A6F",
"list.activeSelectionBackground": "#004454",
// "list.activeSelectionForeground": "",
"list.focusBackground": "#005A6F",
......
......@@ -6,7 +6,6 @@
"dropdown.background": "#001733",
"list.focusBackground": "#ffffff60",
"list.activeSelectionBackground": "#ffffff50",
"list.focusAndSelectionBackground": "#ffffff60",
"list.inactiveSelectionBackground": "#ffffff40",
"list.hoverBackground": "#ffffff30",
"list.dropBackground": "#ffffff60",
......
......@@ -147,7 +147,6 @@ export const listFocusBackground = registerColor('list.focusBackground', { dark:
export const listActiveSelectionBackground = registerColor('list.activeSelectionBackground', { dark: '#0E639C', light: '#4FA7FF', hc: null }, nls.localize('listActiveSelectionBackground', "List/Tree background color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not."));
export const listInactiveSelectionBackground = registerColor('list.inactiveSelectionBackground', { dark: '#3F3F46', light: '#CCCEDB', hc: null }, nls.localize('listInactiveSelectionBackground', "List/Tree background color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not."));
export const listActiveSelectionForeground = registerColor('list.activeSelectionForeground', { dark: Color.white, light: Color.white, hc: Color.white }, nls.localize('listActiveSelectionForeground', "List/Tree foreground color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not."));
export const listFocusAndSelectionBackground = registerColor('list.focusAndSelectionBackground', { dark: '#094771', light: '#3399FF', hc: null }, nls.localize('listFocusAndSelectionBackground', "List/Tree background color for the focused and selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not. This color wins over the individual selection and focus colors."));
export const listHoverBackground = registerColor('list.hoverBackground', { dark: '#2A2D2E', light: '#F0F0F0', hc: null }, nls.localize('listHoverBackground', "List/Tree background when hovering over items using the mouse."));
export const listDropBackground = registerColor('list.dropBackground', { dark: '#383B3D', light: '#DDECFF', hc: null }, nls.localize('listDropBackground', "List/Tree drag and drop background when moving items around using the mouse."));
export const listHighlightForeground = registerColor('list.highlightForeground', { dark: '#219AE4', light: '#186B9E', hc: '#219AE4' }, nls.localize('highlight', 'List/Tree foreground color of the match highlights when searching inside the list/tree.'));
......
......@@ -6,7 +6,7 @@
'use strict';
import { ITheme, IThemeService } from 'vs/platform/theme/common/themeService';
import { inputBackground, inputForeground, ColorIdentifier, selectForeground, selectBackground, selectBorder, inputBorder, foreground, editorBackground, contrastBorder, inputActiveOptionBorder, listFocusBackground, listActiveSelectionBackground, listActiveSelectionForeground, listFocusAndSelectionBackground, listInactiveSelectionBackground, listHoverBackground, listDropBackground, pickerGroupBorder, pickerGroupForeground, widgetShadow, inputValidationInfoBorder, inputValidationInfoBackground, inputValidationWarningBorder, inputValidationWarningBackground, inputValidationErrorBorder, inputValidationErrorBackground, activeContrastBorder, buttonForeground, buttonBackground, buttonHoverBackground } from 'vs/platform/theme/common/colorRegistry';
import { inputBackground, inputForeground, ColorIdentifier, selectForeground, selectBackground, selectBorder, inputBorder, foreground, editorBackground, contrastBorder, inputActiveOptionBorder, listFocusBackground, listActiveSelectionBackground, listActiveSelectionForeground, listInactiveSelectionBackground, listHoverBackground, listDropBackground, pickerGroupBorder, pickerGroupForeground, widgetShadow, inputValidationInfoBorder, inputValidationInfoBackground, inputValidationWarningBorder, inputValidationWarningBackground, inputValidationErrorBorder, inputValidationErrorBackground, activeContrastBorder, buttonForeground, buttonBackground, buttonHoverBackground, ColorFunction, darken } from 'vs/platform/theme/common/colorRegistry';
import { IDisposable } from 'vs/base/common/lifecycle';
import { SIDE_BAR_SECTION_HEADER_BACKGROUND } from 'vs/workbench/common/theme';
......@@ -14,11 +14,16 @@ export interface IThemable {
style(colors: { [name: string]: ColorIdentifier }): void;
}
export function attachStyler(themeService: IThemeService, widget: IThemable, optionsMapping: { [optionsKey: string]: ColorIdentifier }): IDisposable {
export function attachStyler(themeService: IThemeService, widget: IThemable, optionsMapping: { [optionsKey: string]: ColorIdentifier | ColorFunction }): IDisposable {
function applyStyles(theme: ITheme): void {
const styles = Object.create(null);
for (let key in optionsMapping) {
styles[key] = theme.getColor(optionsMapping[key]);
const value = optionsMapping[key];
if (typeof value === 'string') {
styles[key] = theme.getColor(value);
} else if (typeof value === 'function') {
styles[key] = value(theme);
}
}
widget.style(styles);
......@@ -142,7 +147,7 @@ export function attachQuickOpenStyler(widget: IThemable, themeService: IThemeSer
listFocusBackground: (style && style.listFocusBackground) || listFocusBackground,
listActiveSelectionBackground: (style && style.listActiveSelectionBackground) || listActiveSelectionBackground,
listActiveSelectionForeground: (style && style.listActiveSelectionForeground) || listActiveSelectionForeground,
listFocusAndSelectionBackground: (style && style.listFocusAndSelectionBackground) || listFocusAndSelectionBackground,
listFocusAndSelectionBackground: style && style.listFocusAndSelectionBackground || darken(listActiveSelectionBackground, 0.1),
listFocusAndSelectionForeground: (style && style.listFocusAndSelectionForeground) || listActiveSelectionForeground,
listInactiveSelectionBackground: (style && style.listInactiveSelectionBackground) || listInactiveSelectionBackground,
listHoverBackground: (style && style.listHoverBackground) || listHoverBackground,
......@@ -172,7 +177,7 @@ export function attachListStyler(widget: IThemable, themeService: IThemeService,
listFocusBackground: (style && style.listFocusBackground) || listFocusBackground,
listActiveSelectionBackground: (style && style.listActiveSelectionBackground) || listActiveSelectionBackground,
listActiveSelectionForeground: (style && style.listActiveSelectionForeground) || listActiveSelectionForeground,
listFocusAndSelectionBackground: (style && style.listFocusAndSelectionBackground) || listFocusAndSelectionBackground,
listFocusAndSelectionBackground: style && style.listFocusAndSelectionBackground || darken(listActiveSelectionBackground, 0.1),
listFocusAndSelectionForeground: (style && style.listFocusAndSelectionForeground) || listActiveSelectionForeground,
listInactiveFocusBackground: (style && style.listInactiveFocusBackground),
listInactiveSelectionBackground: (style && style.listInactiveSelectionBackground) || listInactiveSelectionBackground,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册