vscode-languageclient
Advanced tools
Comparing version 8.0.2-next.2 to 8.0.2-next.3
@@ -58,3 +58,3 @@ import { TextDocument, TextDocumentChangeEvent, TextDocumentWillSaveEvent, TextEdit as VTextEdit, DocumentSelector as VDocumentSelector, Event } from 'vscode'; | ||
dispose(): void; | ||
forceDelivery(): void; | ||
forceDelivery(): Promise<void>; | ||
getProvider(document: TextDocument): { | ||
@@ -61,0 +61,0 @@ send: (event: TextDocumentChangeEvent) => Promise<void>; |
@@ -172,5 +172,12 @@ "use strict"; | ||
// Use this force delivery to track boolean state. Otherwise we might call two times. | ||
this.forceDelivery(); | ||
await this.forceDelivery(); | ||
this._changeDelayer.uri = event.document.uri.toString(); | ||
} | ||
// Usually we return the promise that signals that the data has been | ||
// handed of to the network. With delayed change notification we can't | ||
// do that since it would make the sendNotification call wait until the | ||
// change delayer resolves and would therefore defeat the purpose. We | ||
// instead return the change delayer and ensure via forceDocumentSync | ||
// that before sending other notification / request the document sync | ||
// has actually happened. | ||
return this._changeDelayer.delayer.trigger(() => doSend(event)); | ||
@@ -183,2 +190,3 @@ } | ||
}; | ||
// See comment above. | ||
return this._changeDelayer.delayer.trigger(() => doSend(event), -1); | ||
@@ -221,3 +229,3 @@ } | ||
} | ||
forceDelivery() { | ||
async forceDelivery() { | ||
if (this._forcingDelivery || !this._changeDelayer) { | ||
@@ -228,3 +236,3 @@ return; | ||
this._forcingDelivery = true; | ||
this._changeDelayer.delayer.forceDelivery(); | ||
return this._changeDelayer.delayer.forceDelivery(); | ||
} | ||
@@ -231,0 +239,0 @@ finally { |
{ | ||
"name": "vscode-languageclient", | ||
"description": "VSCode Language client implementation", | ||
"version": "8.0.2-next.2", | ||
"version": "8.0.2-next.3", | ||
"author": "Microsoft Corporation", | ||
@@ -34,3 +34,3 @@ "license": "MIT", | ||
"semver": "^7.3.5", | ||
"vscode-languageserver-protocol": "3.17.2-next.2" | ||
"vscode-languageserver-protocol": "3.17.2-next.3" | ||
}, | ||
@@ -37,0 +37,0 @@ "scripts": { |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
636751
12415
+ Addedvscode-languageserver-protocol@3.17.2-next.3(transitive)
+ Addedvscode-languageserver-types@3.17.2-next.2(transitive)
- Removedvscode-languageserver-protocol@3.17.2-next.2(transitive)
- Removedvscode-languageserver-types@3.17.2-next.1(transitive)