From 8872ae155204beb08353f1104d2061f28da81eeb Mon Sep 17 00:00:00 2001 From: Jonathan McPherson Date: Thu, 16 Jan 2025 16:26:55 -0800 Subject: [PATCH] always "allow" file uploads/downloads in desktop mode --- .../electron-sandbox/environmentService.ts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/vs/workbench/services/environment/electron-sandbox/environmentService.ts b/src/vs/workbench/services/environment/electron-sandbox/environmentService.ts index 1f25e5b8aee..bfe6f6d6844 100644 --- a/src/vs/workbench/services/environment/electron-sandbox/environmentService.ts +++ b/src/vs/workbench/services/environment/electron-sandbox/environmentService.ts @@ -152,6 +152,20 @@ export class NativeWorkbenchEnvironmentService extends AbstractNativeEnvironment @memoize get filesToWait(): IPathsToWaitFor | undefined { return this.configuration.filesToWait; } + // --- Start Positron --- + // Always file downloads and uploads on Positron Desktop. These can be + // disabled in browser mode for security reasons (see + // BrowserWorkbenchEnvironmentService), but are always enabled in the + // desktop/Electron configuration. + get isEnabledFileDownloads(): boolean { + return true; + } + + get isEnabledFileUploads(): boolean { + return true; + } + // --- End Positron --- + constructor( private readonly configuration: INativeWindowConfiguration, productService: IProductService