Add tab coloring by server group (#383)

This commit is contained in:
Matt Irvine
2017-12-20 18:21:48 -08:00
committed by GitHub
parent 3ffafbe5bc
commit b1b3a92717
14 changed files with 152 additions and 8 deletions

View File

@@ -240,6 +240,11 @@ let registryProperties = {
'description': localize('sql.showBatchTime', '[Optional] Should execution time be shown for individual batches'),
'default': false
},
'sql.enableTabColors': {
'type': 'boolean',
'description': localize('sql.enableTabColors', 'True to color tabs based on the server group of their active connection, false otherwise'),
'default': true
},
'mssql.intelliSense.enableIntelliSense': {
'type': 'boolean',
'default': true,

View File

@@ -252,4 +252,11 @@ export class QueryInput extends EditorInput implements IEncodingSupport, IConnec
this._currentEventCallbacks = dispose(this._currentEventCallbacks);
this._currentEventCallbacks = callbacks;
}
/**
* Get the color that should be displayed
*/
public get tabColor(): string {
return this._connectionManagementService.getTabColorForUri(this.uri);
}
}