From 05e6a5bdda210d99fa69a11d43bfe0c64b6d7ab2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=83=9F=E9=9B=80?= Date: Mon, 20 Jan 2025 16:40:22 +0800 Subject: [PATCH] fix drag file with err uri --- packages/core/src/browser/shell/application-shell.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/packages/core/src/browser/shell/application-shell.ts b/packages/core/src/browser/shell/application-shell.ts index b13081abadb88..7336a6fd2ea93 100644 --- a/packages/core/src/browser/shell/application-shell.ts +++ b/packages/core/src/browser/shell/application-shell.ts @@ -574,13 +574,7 @@ export class ApplicationShell extends Widget { // the files were dragged from the outside the workspace Array.from(event.dataTransfer.files).forEach(file => { if (file.path) { - const fileUri = URI.fromComponents({ - scheme: 'file', - path: file.path, - authority: '', - query: '', - fragment: '' - }); + const fileUri = URI.fromFilePath(file.path); openUri(fileUri); } });