mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-14 01:25:40 -05:00
changed the icons for the completion list based on the sql type (#112)
* changed the icons for the completion list based on the sql type
This commit is contained in:
@@ -562,7 +562,7 @@ namespace Microsoft.SqlTools.ServiceLayer.LanguageServices
|
||||
{
|
||||
|
||||
List<CompletionItem> completions = new List<CompletionItem>();
|
||||
|
||||
|
||||
foreach (var autoCompleteItem in suggestions)
|
||||
{
|
||||
string insertText = GetCompletionItemInsertName(autoCompleteItem);
|
||||
@@ -576,21 +576,22 @@ namespace Microsoft.SqlTools.ServiceLayer.LanguageServices
|
||||
kind = CompletionItemKind.Field;
|
||||
break;
|
||||
case DeclarationType.Table:
|
||||
kind = CompletionItemKind.Method;
|
||||
break;
|
||||
case DeclarationType.Database:
|
||||
case DeclarationType.View:
|
||||
kind = CompletionItemKind.File;
|
||||
break;
|
||||
case DeclarationType.Server:
|
||||
case DeclarationType.Database:
|
||||
kind = CompletionItemKind.Method;
|
||||
break;
|
||||
case DeclarationType.ScalarValuedFunction:
|
||||
case DeclarationType.TableValuedFunction:
|
||||
case DeclarationType.BuiltInFunction:
|
||||
kind = CompletionItemKind.Value;
|
||||
break;
|
||||
default:
|
||||
kind = CompletionItemKind.Variable;
|
||||
kind = CompletionItemKind.Unit;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// convert the completion item candidates into CompletionItems
|
||||
completions.Add(CreateCompletionItem(autoCompleteItem.Title, autoCompleteItem.Title, insertText, kind, row, startColumn, endColumn));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user