mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-22 09:35:37 -05:00
enable provider/extension side copy to clipboard support (#23363)
* improve copy data experience * add copy result handler * refactoring * updates * add thirdparty notice for TextCopy nuget package * add await * comments
This commit is contained in:
@@ -414,6 +414,15 @@ export class ExtHostDataProtocol extends ExtHostDataProtocolShape {
|
||||
return this._resolveProvider<azdata.QueryProvider>(handle).saveResults(requestParams);
|
||||
}
|
||||
|
||||
override $copyResults(handle: number, requestParams: azdata.CopyResultsRequestParams): Thenable<void> {
|
||||
const provider = this._resolveProvider<azdata.QueryProvider>(handle);
|
||||
if (provider.copyResults) {
|
||||
return provider.copyResults(requestParams);
|
||||
} else {
|
||||
throw new Error(`copyResults() is not implemented by the provider`);
|
||||
}
|
||||
}
|
||||
|
||||
// Edit Data handlers
|
||||
override $commitEdit(handle: number, ownerUri: string): Thenable<void> {
|
||||
return this._resolveProvider<azdata.QueryProvider>(handle).commitEdit(ownerUri);
|
||||
|
||||
Reference in New Issue
Block a user