diff --git a/src/sql/workbench/browser/modal/optionsDialog.ts b/src/sql/workbench/browser/modal/optionsDialog.ts index 6c8ea4433c..d0af6a3ce6 100644 --- a/src/sql/workbench/browser/modal/optionsDialog.ts +++ b/src/sql/workbench/browser/modal/optionsDialog.ts @@ -26,7 +26,6 @@ import { IThemeService, IColorTheme } from 'vs/platform/theme/common/themeServic import { ILogService } from 'vs/platform/log/common/log'; import { IAdsTelemetryService } from 'sql/platform/telemetry/common/telemetry'; import { attachModalDialogStyler } from 'sql/workbench/common/styler'; -import { ServiceOptionType } from 'sql/platform/connection/common/interfaces'; import { ILayoutService } from 'vs/platform/layout/browser/layoutService'; import { GroupHeaderBackground } from 'sql/platform/theme/common/colorRegistry'; import { ITextResourcePropertiesService } from 'vs/editor/common/services/textResourceConfiguration'; @@ -75,16 +74,9 @@ export class OptionsDialog extends Modal { attachModalDialogStyler(this, this._themeService); if (this.backButton) { this.backButton.onDidClick(() => this.cancel()); - //styler.attachButtonStyler(this.backButton, this._themeService, { buttonBackground: SIDE_BAR_BACKGROUND, buttonHoverBackground: SIDE_BAR_BACKGROUND }); } - // {{SQL CARBON TODO}} - theming this.addFooterButton(localize('optionsDialog.ok', "OK"), () => this.ok()); this.addFooterButton(this.options.cancelLabel || localize('optionsDialog.cancel', "Cancel"), () => this.cancel(), 'right', true); - // let okButton = this.addFooterButton(localize('optionsDialog.ok', "OK"), () => this.ok()); - // let closeButton = this.addFooterButton(this.options.cancelLabel || localize('optionsDialog.cancel', "Cancel"), () => this.cancel(), 'right', true); - // Theme styler - //styler.attachButtonStyler(okButton, this._themeService); - //styler.attachButtonStyler(closeButton, this._themeService); this._register(this._themeService.onDidColorThemeChange(e => this.updateTheme(e))); this.updateTheme(this._themeService.getColorTheme()); } @@ -135,25 +127,6 @@ export class OptionsDialog extends Modal { } } - private registerStyling(): void { - // Theme styler - for (let optionName in this._optionElements) { - // {{SQL CARBON TODO}} - styling - //let widget: Widget = this._optionElements[optionName].optionWidget; - let option = this._optionElements[optionName].option; - switch (option.valueType) { - case ServiceOptionType.category: - case ServiceOptionType.boolean: - //this.disposableStore.add(styler.attachSelectBoxStyler(widget, this._themeService)); - break; - case ServiceOptionType.string: - case ServiceOptionType.password: - case ServiceOptionType.number: - //this.disposableStore.add(styler.attachInputBoxStyler(widget, this._themeService)); - } - } - } - private get options(): IOptionsDialogOptions { return this._modalOptions as IOptionsDialogOptions; } @@ -215,7 +188,6 @@ export class OptionsDialog extends Modal { append(this._optionGroupsContainer!, bodyContainer); } this.updateTheme(this._themeService.getColorTheme()); - this.registerStyling(); this.show(); } diff --git a/src/sql/workbench/contrib/notebook/browser/calloutDialog/imageCalloutDialog.ts b/src/sql/workbench/contrib/notebook/browser/calloutDialog/imageCalloutDialog.ts index 3ade683c57..b67fc5cde2 100644 --- a/src/sql/workbench/contrib/notebook/browser/calloutDialog/imageCalloutDialog.ts +++ b/src/sql/workbench/contrib/notebook/browser/calloutDialog/imageCalloutDialog.ts @@ -101,7 +101,6 @@ export class ImageCalloutDialog extends Modal { this.addFooterButton(constants.insertButtonText, () => this.insert()); this.addFooterButton(constants.cancelButtonText, () => this.cancel(), undefined, true); - this.registerListeners(); } protected renderBody(container: HTMLElement) { @@ -194,12 +193,6 @@ export class ImageCalloutDialog extends Modal { })); } - private registerListeners(): void { - // {{SQL CARBON TODO}} - attach styles? - // this._register(styler.attachInputBoxStyler(this._imageUrlInputBox, this._themeService)); - // this._register(styler.attachToggleStyler(this._imageEmbedCheckbox, this._themeService)); - } - public insert(): void { this.hide('ok'); let imgPath = unquoteText(this._imageUrlInputBox.value); diff --git a/src/sql/workbench/contrib/notebook/browser/calloutDialog/linkCalloutDialog.ts b/src/sql/workbench/contrib/notebook/browser/calloutDialog/linkCalloutDialog.ts index a04e988b05..b677852053 100644 --- a/src/sql/workbench/contrib/notebook/browser/calloutDialog/linkCalloutDialog.ts +++ b/src/sql/workbench/contrib/notebook/browser/calloutDialog/linkCalloutDialog.ts @@ -96,7 +96,6 @@ export class LinkCalloutDialog extends Modal { this.addFooterButton(constants.insertButtonText, () => this.insert()); this.addFooterButton(constants.cancelButtonText, () => this.cancel(), undefined, true); - this.registerListeners(); } protected renderBody(container: HTMLElement) { @@ -141,12 +140,6 @@ export class LinkCalloutDialog extends Modal { DOM.append(linkAddressRow, linkAddressInputContainer); } - private registerListeners(): void { - // {{SQL CARBON TODO}} - apply styles - // this._register(styler.attachInputBoxStyler(this._linkTextInputBox, this._themeService)); - // this._register(styler.attachInputBoxStyler(this._linkUrlInputBox, this._themeService)); - } - protected override onAccept(e?: StandardKeyboardEvent) { // EventHelper.stop() will call preventDefault. Without it, text cell will insert an extra newline when pressing enter on dialog DOM.EventHelper.stop(e, true); diff --git a/src/sql/workbench/contrib/notebook/browser/find/notebookFindWidget.ts b/src/sql/workbench/contrib/notebook/browser/find/notebookFindWidget.ts index 809746f87a..4a90fd9676 100644 --- a/src/sql/workbench/contrib/notebook/browser/find/notebookFindWidget.ts +++ b/src/sql/workbench/contrib/notebook/browser/find/notebookFindWidget.ts @@ -21,7 +21,7 @@ import { IOverlayWidget, IOverlayWidgetPosition, OverlayWidgetPositionPreference import { FIND_IDS, CONTEXT_FIND_INPUT_FOCUSED } from 'vs/editor/contrib/find/browser/findModel'; import { FindReplaceState, FindReplaceStateChangedEvent } from 'vs/editor/contrib/find/browser/findState'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; -import { IColorTheme, IThemeService } from 'vs/platform/theme/common/themeService'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; import { IEditorAction } from 'vs/editor/common/editorCommon'; import { IDisposable } from 'vs/base/common/lifecycle'; import { defaultInputBoxStyles, defaultToggleStyles } from 'vs/platform/theme/browser/defaultStyles'; @@ -159,9 +159,6 @@ export class FindWidget extends Widget implements IOverlayWidget, IVerticalSashL this._notebookController.addOverlayWidget(this); - this._applyTheme(themeService.getColorTheme()); - this._register(themeService.onDidColorThemeChange(this._applyTheme.bind(this))); - this.onkeyup(this._domNode, e => { if (e.equals(KeyCode.Escape)) { this._state.change({ isRevealed: false, searchScope: null }, false); @@ -299,23 +296,6 @@ export class FindWidget extends Widget implements IOverlayWidget, IVerticalSashL } } - private _applyTheme(theme: IColorTheme) { - // {{SQL CARBON TODO}} - reenable styles - // let inputStyles: IFindInputStyles = { - // inputActiveOptionBorder: theme.getColor(colors.inputActiveOptionBorder), - // inputBackground: theme.getColor(colors.inputBackground), - // inputForeground: theme.getColor(colors.inputForeground), - // inputBorder: theme.getColor(colors.inputBorder), - // inputValidationInfoBackground: theme.getColor(colors.inputValidationInfoBackground), - // inputValidationInfoBorder: theme.getColor(colors.inputValidationInfoBorder), - // inputValidationWarningBackground: theme.getColor(colors.inputValidationWarningBackground), - // inputValidationWarningBorder: theme.getColor(colors.inputValidationWarningBorder), - // inputValidationErrorBackground: theme.getColor(colors.inputValidationErrorBackground), - // inputValidationErrorBorder: theme.getColor(colors.inputValidationErrorBorder) - // }; - //this._findInput.style(inputStyles); - } - // ----- Public public focusFindInput(): void { diff --git a/src/sql/workbench/contrib/profiler/browser/profilerFindWidget.ts b/src/sql/workbench/contrib/profiler/browser/profilerFindWidget.ts index 5817927bb6..b433346879 100644 --- a/src/sql/workbench/contrib/profiler/browser/profilerFindWidget.ts +++ b/src/sql/workbench/contrib/profiler/browser/profilerFindWidget.ts @@ -19,7 +19,7 @@ import { Sash, ISashEvent, Orientation, IVerticalSashLayoutProvider } from 'vs/b import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IOverlayWidget, IOverlayWidgetPosition, OverlayWidgetPositionPreference } from 'vs/editor/browser/editorBrowser'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; -import { IColorTheme, IThemeService } from 'vs/platform/theme/common/themeService'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; import { IEditorAction } from 'vs/editor/common/editorCommon'; import { IDisposable } from 'vs/base/common/lifecycle'; import { FindReplaceState, FindReplaceStateChangedEvent } from 'vs/editor/contrib/find/browser/findState'; @@ -155,9 +155,6 @@ export class FindWidget extends Widget implements IOverlayWidget, IVerticalSashL }); this._tableController.addOverlayWidget(this); - - this._applyTheme(themeService.getColorTheme()); - this._register(themeService.onDidColorThemeChange(this._applyTheme.bind(this))); } // ----- IOverlayWidget API @@ -290,23 +287,6 @@ export class FindWidget extends Widget implements IOverlayWidget, IVerticalSashL } } - private _applyTheme(theme: IColorTheme) { - // {{SQL CARBON TODO}} - styles - // let inputStyles: IFindInputStyles = { - // inputActiveOptionBorder: theme.getColor(colors.inputActiveOptionBorder), - // inputBackground: theme.getColor(colors.inputBackground), - // inputForeground: theme.getColor(colors.inputForeground), - // inputBorder: theme.getColor(colors.inputBorder), - // inputValidationInfoBackground: theme.getColor(colors.inputValidationInfoBackground), - // inputValidationInfoBorder: theme.getColor(colors.inputValidationInfoBorder), - // inputValidationWarningBackground: theme.getColor(colors.inputValidationWarningBackground), - // inputValidationWarningBorder: theme.getColor(colors.inputValidationWarningBorder), - // inputValidationErrorBackground: theme.getColor(colors.inputValidationErrorBackground), - // inputValidationErrorBorder: theme.getColor(colors.inputValidationErrorBorder) - // }; - // this._findInput.style(inputStyles); - } - // ----- Public public focusFindInput(): void { diff --git a/src/sql/workbench/services/backupRestoreUrlBrowser/browser/urlBrowserDialog.ts b/src/sql/workbench/services/backupRestoreUrlBrowser/browser/urlBrowserDialog.ts index 65b1f34bac..91881aa1ad 100644 --- a/src/sql/workbench/services/backupRestoreUrlBrowser/browser/urlBrowserDialog.ts +++ b/src/sql/workbench/services/backupRestoreUrlBrowser/browser/urlBrowserDialog.ts @@ -111,9 +111,6 @@ export class BackupRestoreUrlBrowserDialog extends Modal { })); this._register(this.backButton); - - // {{SQL CARBON TODO}} - style - //this._register(attachButtonStyler(this.backButton, this._themeService, { buttonBackground: SIDE_BAR_BACKGROUND, buttonHoverBackground: SIDE_BAR_BACKGROUND })); } let tableContainer: HTMLElement = DOM.append(DOM.append(this._body, DOM.$('.option-section')), DOM.$('table.url-table-content')); diff --git a/src/vs/base/common/themables.ts b/src/vs/base/common/themables.ts index 9b853fb386..05857b583b 100644 --- a/src/vs/base/common/themables.ts +++ b/src/vs/base/common/themables.ts @@ -38,32 +38,6 @@ export namespace ThemeIcon { const ThemeIconIdRegex = new RegExp(`^(${iconNameExpression})(${iconModifierExpression})?$`); - - // {{SQL CARBON TODO}} - do we need the edit block below - // export function asClassNameArray(icon: CSSIcon): string[] { - // if (icon instanceof Codicon) { - // return ['codicon', 'codicon-' + icon.id]; - // } - // const match = cssIconIdRegex.exec(icon.id); - // if (!match) { - // return asClassNameArray(Codicon.error); - // } - // const [, id, modifier] = match; - - // // {{SQL CARBON EDIT}} Modifying method to not add 'codicon' in front of sql carbon icons. - // let sqlCarbonIcons: string[] = [SqlIconId.activeConnectionsAction, SqlIconId.addServerAction, SqlIconId.addServerGroupAction, SqlIconId.serverPage]; - // if (sqlCarbonIcons.includes(id)) { - // return ['codicon', id]; - // // {{SQL CARBON EDIT}} End of edit - // } else { - // const classNames = ['codicon', 'codicon-' + id]; - // if (modifier) { - // classNames.push('codicon-modifier-' + modifier.substr(1)); - // } - // return classNames; - // } - // } - export function asClassNameArray(icon: ThemeIcon): string[] { const match = ThemeIconIdRegex.exec(icon.id); if (!match) { diff --git a/src/vs/platform/extensionManagement/common/extensionGalleryService.ts b/src/vs/platform/extensionManagement/common/extensionGalleryService.ts index 3f4421afbe..73d9fca093 100644 --- a/src/vs/platform/extensionManagement/common/extensionGalleryService.ts +++ b/src/vs/platform/extensionManagement/common/extensionGalleryService.ts @@ -1126,7 +1126,7 @@ abstract class AbstractExtensionGalleryService implements IExtensionGalleryServi if (result) { const r = result.results[0]; const galleryExtensions = r.extensions; - // {{SQL CARBON TODO}} + // {{SQL CARBON EDIT}} galleryExtensions.forEach(e => sortExtensionVersions(e.versions, TargetPlatform.UNIVERSAL)); // const resultCount = r.resultMetadata && r.resultMetadata.filter(m => m.metadataType === 'ResultCount')[0]; {{SQL CARBON EDIT}} comment out for no unused // const total = resultCount && resultCount.metadataItems.filter(i => i.name === 'TotalCount')[0].count || 0; {{SQL CARBON EDIT}} comment out for no unused diff --git a/src/vs/workbench/services/themes/browser/workbenchThemeService.ts b/src/vs/workbench/services/themes/browser/workbenchThemeService.ts index 77674d3739..fd391a7198 100644 --- a/src/vs/workbench/services/themes/browser/workbenchThemeService.ts +++ b/src/vs/workbench/services/themes/browser/workbenchThemeService.ts @@ -44,10 +44,6 @@ import { ILanguageService } from 'vs/editor/common/languages/language'; // implementation -// {{SQL CARBON TODO}} - default theme? -// const DEFAULT_COLOR_THEME_ID = 'vs sql-theme-carbon-themes-light_carbon-json'; // {{SQL CARBON EDIT}} -// const DEFAULT_LIGHT_COLOR_THEME_ID = 'vs vscode-theme-defaults-themes-light_plus-json'; - const PERSISTED_OS_COLOR_SCHEME = 'osColorScheme'; const PERSISTED_OS_COLOR_SCHEME_SCOPE = StorageScope.APPLICATION; // the OS scheme depends on settings in the OS