mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Merge from vscode 3c6f6af7347d38e87bc6406024e8dcf9e9bce229 (#8962)
* Merge from vscode 3c6f6af7347d38e87bc6406024e8dcf9e9bce229 * skip failing tests * update mac build image
This commit is contained in:
committed by
Karl Burtram
parent
0eaee18dc4
commit
fefe1454de
@@ -104,6 +104,7 @@ export interface TokenStylingDefaultRule {
|
||||
export interface TokenStylingRule {
|
||||
match(classification: TokenClassification): number;
|
||||
value: TokenStyle;
|
||||
selector: TokenClassification;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -294,7 +295,8 @@ class TokenClassificationRegistry implements ITokenClassificationRegistry {
|
||||
public getTokenStylingRule(selector: TokenClassification, value: TokenStyle): TokenStylingRule {
|
||||
return {
|
||||
match: this.newMatcher(selector),
|
||||
value
|
||||
value,
|
||||
selector
|
||||
};
|
||||
}
|
||||
|
||||
@@ -376,11 +378,11 @@ function registerDefaultClassifications(): void {
|
||||
|
||||
registerTokenType('namespace', nls.localize('namespace', "Style for namespaces."), [['entity.name.namespace']]);
|
||||
|
||||
registerTokenType('type', nls.localize('type', "Style for types."), [['entity.name.type'], ['entity.name.class'], ['support.type'], ['support.class']]);
|
||||
registerTokenType('type', nls.localize('type', "Style for types."), [['entity.name.type'], ['support.type'], ['support.class']]);
|
||||
registerTokenType('struct', nls.localize('struct', "Style for structs."), [['storage.type.struct']], 'type');
|
||||
registerTokenType('class', nls.localize('class', "Style for classes."), [['entity.name.class']], 'type');
|
||||
registerTokenType('interface', nls.localize('interface', "Style for interfaces."), undefined, 'type');
|
||||
registerTokenType('enum', nls.localize('enum', "Style for enums."), undefined, 'type');
|
||||
registerTokenType('class', nls.localize('class', "Style for classes."), [['entity.name.type.class']], 'type');
|
||||
registerTokenType('interface', nls.localize('interface', "Style for interfaces."), [['entity.name.type.interface']], 'type');
|
||||
registerTokenType('enum', nls.localize('enum', "Style for enums."), [['entity.name.type.enum']], 'type');
|
||||
registerTokenType('typeParameter', nls.localize('typeParameter', "Style for type parameters."), undefined, 'type');
|
||||
|
||||
registerTokenType('function', nls.localize('function', "Style for functions"), [['entity.name.function'], ['support.function']]);
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { isWindows, isMacintosh } from 'vs/base/common/platform';
|
||||
import { ipcMain as ipc, nativeTheme } from 'electron';
|
||||
import { systemPreferences, ipcMain as ipc } from 'electron';
|
||||
import { IStateService } from 'vs/platform/state/node/state';
|
||||
import { createDecorator } from 'vs/platform/instantiation/common/instantiation';
|
||||
|
||||
@@ -42,14 +42,14 @@ export class ThemeMainService implements IThemeMainService {
|
||||
}
|
||||
|
||||
getBackgroundColor(): string {
|
||||
if (isWindows && nativeTheme.shouldUseInvertedColorScheme) {
|
||||
if (isWindows && systemPreferences.isInvertedColorScheme()) {
|
||||
return DEFAULT_BG_HC_BLACK;
|
||||
}
|
||||
|
||||
let background = this.stateService.getItem<string | null>(THEME_BG_STORAGE_KEY, null);
|
||||
if (!background) {
|
||||
let baseTheme: string;
|
||||
if (isWindows && nativeTheme.shouldUseInvertedColorScheme) {
|
||||
if (isWindows && systemPreferences.isInvertedColorScheme()) {
|
||||
baseTheme = 'hc-black';
|
||||
} else {
|
||||
baseTheme = this.stateService.getItem<string>(THEME_STORAGE_KEY, 'vs-dark').split(' ')[0];
|
||||
|
||||
Reference in New Issue
Block a user