mirror of
https://github.com/Microsoft/vscode
synced 2024-10-13 06:48:17 +00:00
fixes #24119
This commit is contained in:
parent
df2cdb1a42
commit
a188171bf8
|
@ -620,11 +620,8 @@ export class List<T> implements ISpliceable<T>, IDisposable {
|
|||
return mapEvent(this._onPin.event, indexes => this.toListEvent({ indexes }));
|
||||
}
|
||||
|
||||
private _onDOMFocus = new Emitter<void>();
|
||||
get onDOMFocus(): Event<void> { return this._onDOMFocus.event; }
|
||||
|
||||
private _onDOMBlur = new Emitter<void>();
|
||||
get onDOMBlur(): Event<void> { return this._onDOMBlur.event; }
|
||||
readonly onDOMFocus: Event<void>;
|
||||
readonly onDOMBlur: Event<void>;
|
||||
|
||||
private _onDispose = new Emitter<void>();
|
||||
get onDispose(): Event<void> { return this._onDispose.event; }
|
||||
|
@ -660,9 +657,8 @@ export class List<T> implements ISpliceable<T>, IDisposable {
|
|||
|
||||
this.disposables = [this.focus, this.selection, this.view, this._onDispose];
|
||||
|
||||
const tracker = DOM.trackFocus(this.view.domNode);
|
||||
this.disposables.push(tracker.addFocusListener(() => this._onDOMFocus.fire()));
|
||||
this.disposables.push(tracker.addBlurListener(() => this._onDOMBlur.fire()));
|
||||
this.onDOMFocus = mapEvent(domEvent(this.view.domNode, 'focus', true), () => null);
|
||||
this.onDOMBlur = mapEvent(domEvent(this.view.domNode, 'blur', true), () => null);
|
||||
|
||||
if (typeof options.keyboardSupport !== 'boolean' || options.keyboardSupport) {
|
||||
const controller = new KeyboardController(this, this.view);
|
||||
|
|
|
@ -175,6 +175,8 @@ export const listActiveSelectionBackground = registerColor('list.activeSelection
|
|||
export const listActiveSelectionForeground = registerColor('list.activeSelectionForeground', { dark: Color.white, light: Color.white, hc: null }, 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 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 listInactiveSelectionForeground = registerColor('list.inactiveSelectionForeground', { dark: null, light: null, hc: null }, nls.localize('listInactiveSelectionForeground', "List/Tree foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not."));
|
||||
export const listInactiveFocusBackground = registerColor('list.inactiveFocusBackground', { dark: '#313135', light: '#d8dae6', 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 listInactiveFocusForeground = registerColor('list.inactiveFocusForeground', { dark: null, light: null, hc: null }, nls.localize('listInactiveSelectionForeground', "List/Tree foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not."));
|
||||
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 listHoverForeground = registerColor('list.hoverForeground', { dark: null, light: null, hc: null }, nls.localize('listHoverForeground', "List/Tree foreground when hovering over items using the mouse."));
|
||||
export const listDropBackground = registerColor('list.dropBackground', { dark: listFocusBackground, light: listFocusBackground, hc: null }, nls.localize('listDropBackground', "List/Tree drag and drop background when moving items around using the mouse."));
|
||||
|
|
|
@ -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, listFocusForeground, listActiveSelectionBackground, listActiveSelectionForeground, listInactiveSelectionForeground, listInactiveSelectionBackground, listHoverBackground, listHoverForeground, listDropBackground, pickerGroupBorder, pickerGroupForeground, widgetShadow, inputValidationInfoBorder, inputValidationInfoBackground, inputValidationWarningBorder, inputValidationWarningBackground, inputValidationErrorBorder, inputValidationErrorBackground, activeContrastBorder, buttonForeground, buttonBackground, buttonHoverBackground, ColorFunction, lighten, badgeBackground, badgeForeground, progressBarBackground } from 'vs/platform/theme/common/colorRegistry';
|
||||
import { inputBackground, inputForeground, ColorIdentifier, selectForeground, selectBackground, selectBorder, inputBorder, foreground, editorBackground, contrastBorder, inputActiveOptionBorder, listFocusBackground, listFocusForeground, listActiveSelectionBackground, listActiveSelectionForeground, listInactiveSelectionForeground, listInactiveSelectionBackground, listInactiveFocusForeground, listInactiveFocusBackground, listHoverBackground, listHoverForeground, listDropBackground, pickerGroupBorder, pickerGroupForeground, widgetShadow, inputValidationInfoBorder, inputValidationInfoBackground, inputValidationWarningBorder, inputValidationWarningBackground, inputValidationErrorBorder, inputValidationErrorBackground, activeContrastBorder, buttonForeground, buttonBackground, buttonHoverBackground, ColorFunction, lighten, badgeBackground, badgeForeground, progressBarBackground } from 'vs/platform/theme/common/colorRegistry';
|
||||
import { IDisposable } from 'vs/base/common/lifecycle';
|
||||
|
||||
export type styleFn = (colors: { [name: string]: ColorIdentifier }) => void;
|
||||
|
@ -142,6 +142,8 @@ export function attachQuickOpenStyler(widget: IThemable, themeService: IThemeSer
|
|||
listFocusAndSelectionForeground?: ColorIdentifier,
|
||||
listInactiveSelectionBackground?: ColorIdentifier,
|
||||
listInactiveSelectionForeground?: ColorIdentifier,
|
||||
listInactiveFocusBackground?: ColorIdentifier,
|
||||
listInactiveFocusForeground?: ColorIdentifier,
|
||||
listHoverBackground?: ColorIdentifier,
|
||||
listHoverForeground?: ColorIdentifier,
|
||||
listDropBackground?: ColorIdentifier,
|
||||
|
@ -174,6 +176,8 @@ export function attachQuickOpenStyler(widget: IThemable, themeService: IThemeSer
|
|||
listFocusAndSelectionForeground: (style && style.listFocusAndSelectionForeground) || listActiveSelectionForeground,
|
||||
listInactiveSelectionBackground: (style && style.listInactiveSelectionBackground) || listInactiveSelectionBackground,
|
||||
listInactiveSelectionForeground: (style && style.listInactiveSelectionForeground) || listInactiveSelectionForeground,
|
||||
listInactiveFocusBackground: (style && style.listInactiveFocusBackground) || listInactiveFocusBackground,
|
||||
listInactiveFocusForeground: (style && style.listInactiveFocusForeground) || listInactiveFocusForeground,
|
||||
listHoverBackground: (style && style.listHoverBackground) || listHoverBackground,
|
||||
listHoverForeground: (style && style.listHoverForeground) || listHoverForeground,
|
||||
listDropBackground: (style && style.listDropBackground) || listDropBackground,
|
||||
|
@ -190,9 +194,10 @@ export function attachListStyler(widget: IThemable, themeService: IThemeService,
|
|||
listActiveSelectionForeground?: ColorIdentifier,
|
||||
listFocusAndSelectionBackground?: ColorIdentifier,
|
||||
listFocusAndSelectionForeground?: ColorIdentifier,
|
||||
listInactiveFocusBackground?: ColorIdentifier,
|
||||
listInactiveSelectionBackground?: ColorIdentifier,
|
||||
listInactiveSelectionForeground?: ColorIdentifier,
|
||||
listInactiveFocusBackground?: ColorIdentifier,
|
||||
listInactiveFocusForeground?: ColorIdentifier,
|
||||
listHoverBackground?: ColorIdentifier,
|
||||
listHoverForeground?: ColorIdentifier,
|
||||
listDropBackground?: ColorIdentifier,
|
||||
|
@ -208,9 +213,10 @@ export function attachListStyler(widget: IThemable, themeService: IThemeService,
|
|||
listActiveSelectionForeground: (style && style.listActiveSelectionForeground) || listActiveSelectionForeground,
|
||||
listFocusAndSelectionBackground: style && style.listFocusAndSelectionBackground || listActiveSelectionBackground,
|
||||
listFocusAndSelectionForeground: (style && style.listFocusAndSelectionForeground) || listActiveSelectionForeground,
|
||||
listInactiveFocusBackground: (style && style.listInactiveFocusBackground),
|
||||
listInactiveSelectionBackground: (style && style.listInactiveSelectionBackground) || listInactiveSelectionBackground,
|
||||
listInactiveSelectionForeground: (style && style.listInactiveSelectionForeground) || listInactiveSelectionForeground,
|
||||
listInactiveFocusBackground: (style && style.listInactiveFocusBackground) || listInactiveFocusBackground,
|
||||
listInactiveFocusForeground: (style && style.listInactiveFocusForeground) || listInactiveFocusForeground,
|
||||
listHoverBackground: (style && style.listHoverBackground) || listHoverBackground,
|
||||
listHoverForeground: (style && style.listHoverForeground) || listHoverForeground,
|
||||
listDropBackground: (style && style.listDropBackground) || listDropBackground,
|
||||
|
|
|
@ -156,6 +156,10 @@
|
|||
line-height: 15px;
|
||||
}
|
||||
|
||||
.extensions-viewlet > .extensions .extension > .details > .footer > .monaco-action-bar .action-label:not(:empty) {
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
.extensions-viewlet > .extensions .extension.disabled > .icon,
|
||||
.extensions-viewlet > .extensions .extension.disabled > .details > .header-container,
|
||||
.extensions-viewlet > .extensions .extension.disabled > .details > .description
|
||||
|
|
|
@ -27,10 +27,6 @@
|
|||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.scm-viewlet .monaco-list-row > .resource-group:not(:hover) > .actions {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.scm-viewlet .monaco-list-row > .resource {
|
||||
display: flex;
|
||||
height: 100%;
|
||||
|
@ -63,12 +59,16 @@
|
|||
background-position: 50% 50%;
|
||||
}
|
||||
|
||||
|
||||
.scm-viewlet .monaco-list .monaco-list-row > .resource-group > .actions,
|
||||
.scm-viewlet .monaco-list .monaco-list-row > .resource > .actions {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.scm-viewlet .monaco-list .monaco-list-row.selected > .resource-group > .actions,
|
||||
.scm-viewlet .monaco-list .monaco-list-row.focused > .resource-group > .actions,
|
||||
.scm-viewlet .monaco-list .monaco-list-row.selected > .resource > .actions,
|
||||
.scm-viewlet .monaco-list .monaco-list-row.focused > .resource > .actions,
|
||||
.scm-viewlet .monaco-list:not(.selection-multiple) .monaco-list-row > .resource:hover > .actions {
|
||||
display: block;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue