mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 13:25:09 +00:00
Add showWorkspaceLoadedNotification to vscode client
This allows users to control whether or not they want to see the "workspace loaded" notification. This is done on the server side using InitializationOptions which are provided by the client. By default show_workspace_loaded is true, meaning the notification is sent.
This commit is contained in:
parent
ce118da149
commit
0dcb1cb569
8 changed files with 78 additions and 22 deletions
|
@ -8,6 +8,7 @@ export class Config {
|
|||
public highlightingOn = true;
|
||||
public enableEnhancedTyping = true;
|
||||
public raLspServerPath = RA_LSP_DEBUG || 'ra_lsp_server';
|
||||
public showWorkspaceLoadedNotification = true;
|
||||
|
||||
private prevEnhancedTyping: null | boolean = null;
|
||||
|
||||
|
@ -24,6 +25,12 @@ export class Config {
|
|||
this.highlightingOn = config.get('highlightingOn') as boolean;
|
||||
}
|
||||
|
||||
if (config.has('showWorkspaceLoadedNotification')) {
|
||||
this.showWorkspaceLoadedNotification = config.get(
|
||||
'showWorkspaceLoadedNotification'
|
||||
) as boolean;
|
||||
}
|
||||
|
||||
if (!this.highlightingOn && Server) {
|
||||
Server.highlighter.removeHighlights();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue