Skip to content

Commit

Permalink
adding event and operator completion item kinds, #2628
Browse files Browse the repository at this point in the history
  • Loading branch information
jrieken committed Apr 18, 2017
1 parent 747488c commit 24ef0ba
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 5 deletions.
2 changes: 2 additions & 0 deletions src/vs/editor/common/modes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,8 @@ export type SuggestionType = 'method'
| 'interface'
| 'module'
| 'property'
| 'event'
| 'operator'
| 'unit'
| 'value'
| 'constant'
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions src/vs/editor/contrib/suggest/browser/media/suggest.css
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.function,
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.constructor { background-image: url('Method_16x.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.field { background-image: url('Field_16x.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.event { background-image: url('Event_16x_vscode.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.operator { background-image: url('Operator_16x_vscode.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.variable { background-image: url('LocalVariable_16x_vscode.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.class { background-image: url('Class_16x.svg'); }
.monaco-editor .suggest-widget .monaco-list .monaco-list-row .icon.interface { background-image: url('Interface_16x.svg'); }
Expand Down Expand Up @@ -252,6 +254,12 @@
.monaco-editor.vs-dark .suggest-widget .monaco-list .monaco-list-row .icon.field,
.monaco-editor.hc-black .suggest-widget .monaco-list .monaco-list-row .icon.field { background-image: url('Field_inverse_16x.svg'); }

.monaco-editor.vs-dark .suggest-widget .monaco-list .monaco-list-row .icon.event,
.monaco-editor.hc-black .suggest-widget .monaco-list .monaco-list-row .icon.event { background-image: url('Event_16x_vscode_inverse.svg'); }

.monaco-editor.vs-dark .suggest-widget .monaco-list .monaco-list-row .icon.operator,
.monaco-editor.hc-black .suggest-widget .monaco-list .monaco-list-row .icon.operator { background-image: url('Operator_16x_vscode_inverse.svg'); }

.monaco-editor.vs-dark .suggest-widget .monaco-list .monaco-list-row .icon.variable,
.monaco-editor.hc-black .suggest-widget .monaco-list .monaco-list-row .icon.variable { background-image: url('LocalVariable_16x_vscode_inverse.svg'); }

Expand Down
10 changes: 6 additions & 4 deletions src/vs/vscode.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2425,20 +2425,22 @@ declare module 'vscode' {
Variable = 5,
Class = 6,
Interface = 7,
Struct = 21,
Module = 8,
Property = 9,
Unit = 10,
Value = 11,
Constant = 20,
Enum = 12,
EnumMember = 19,
Keyword = 13,
Snippet = 14,
Color = 15,
Reference = 17,
File = 16,
Folder = 18
Folder = 18,
EnumMember = 19,
Constant = 20,
Struct = 21,
Event = 22,
Operator = 23
}

/**
Expand Down
2 changes: 2 additions & 0 deletions src/vs/workbench/api/node/extHostTypeConverters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,8 @@ export const CompletionItemKind = {
case types.CompletionItemKind.File: return 'file';
case types.CompletionItemKind.Reference: return 'reference';
case types.CompletionItemKind.Folder: return 'folder';
case types.CompletionItemKind.Event: return 'event';
case types.CompletionItemKind.Operator: return 'operator';
}
return 'property';
},
Expand Down
4 changes: 3 additions & 1 deletion src/vs/workbench/api/node/extHostTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -872,7 +872,9 @@ export enum CompletionItemKind {
Folder = 18,
EnumMember = 19,
Constant = 20,
Struct = 21
Struct = 21,
Event = 22,
Operator = 23
}

export class CompletionItem {
Expand Down

0 comments on commit 24ef0ba

Please sign in to comment.