-
Notifications
You must be signed in to change notification settings - Fork 34
Conversation
Signed-off-by: Yan Zhang <yanzh@microsoft.com>
|
||
|
||
export const enum TypeHierarchyDirection { | ||
Subtypes = 'subtypes', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
different from call-hierarchy, I use string enum here.
'symbol-event', 'symbol-operator', 'symbol-type-parameter' | ||
]; | ||
|
||
export function getThemeIcon(kind: vscode.SymbolKind): vscode.ThemeIcon | undefined { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I extract it here, as it's shared between call-h and type-h.
|
||
private static _key = 'references-view.typeHierarchyMode'; | ||
|
||
private _ctxMode = new ContextKey<TypeHierarchyDirection>('references-view.typeHierarchyMode'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
different from call-h, I directly save value of corresponding enum string into memento object for simplicity.
Here is a test with the same mock extension mentioned in microsoft/vscode#130922 (comment) show-type-hierarchy.mp4 |
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, pushed a commit to change the spelling to 'supertypes'
part of microsoft/vscode#15533
The implementation is mostly copied from call hierarchy.