Skip to content
This repository has been archived by the owner on Jun 19, 2024. It is now read-only.

Commit

Permalink
Support CompletionItemKind.Method
Browse files Browse the repository at this point in the history
Previously, if a registered completion provider returned items with
CompletionItemKind.Method, they would display in the list as properties,
due to not being converted to the corresponding SuggestionType.
  • Loading branch information
sandyarmstrong committed Aug 12, 2016
1 parent 6276dcb commit 8c2cd6d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/vs/editor/browser/standalone/standaloneLanguages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,7 @@ interface ISuggestion2 extends modes.ISuggestion {
}
function convertKind(kind: CompletionItemKind): modes.SuggestionType {
switch (kind) {
case CompletionItemKind.Method: return 'method';
case CompletionItemKind.Function: return 'function';
case CompletionItemKind.Constructor: return 'constructor';
case CompletionItemKind.Field: return 'field';
Expand Down
1 change: 1 addition & 0 deletions src/vs/workbench/api/node/extHostTypeConverters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ export const CompletionItemKind = {

from(kind: types.CompletionItemKind): modes.SuggestionType {
switch (kind) {
case types.CompletionItemKind.Method: return 'method';
case types.CompletionItemKind.Function: return 'function';
case types.CompletionItemKind.Constructor: return 'constructor';
case types.CompletionItemKind.Field: return 'field';
Expand Down

0 comments on commit 8c2cd6d

Please sign in to comment.