@@ -36,7 +36,7 @@ import { ICommandService, CommandsRegistry } from 'vs/platform/commands/common/c
3636import { IListService , ListWidget } from 'vs/platform/list/browser/listService' ;
3737import { RawContextKey } from 'vs/platform/contextkey/common/contextkey' ;
3838import { Schemas } from 'vs/base/common/network' ;
39- import { IDialogService , IConfirmationResult , getConfirmMessage , IFileDialogService } from 'vs/platform/dialogs/common/dialogs' ;
39+ import { IDialogService , IConfirmationResult , getConfirmMessage } from 'vs/platform/dialogs/common/dialogs' ;
4040import { INotificationService , Severity } from 'vs/platform/notification/common/notification' ;
4141import { IEditorService } from 'vs/workbench/services/editor/common/editorService' ;
4242import { Constants } from 'vs/editor/common/core/uint' ;
@@ -982,18 +982,11 @@ const downloadFileHandler = (accessor: ServicesAccessor) => {
982982 }
983983 const explorerContext = getContext ( listService . lastFocusedList ) ;
984984 const textFileService = accessor . get ( ITextFileService ) ;
985- const fileDialogService = accessor . get ( IFileDialogService ) ;
986985
987986 if ( explorerContext . stat ) {
988987 const stats = explorerContext . selection . length > 1 ? explorerContext . selection : [ explorerContext . stat ] ;
989988 stats . forEach ( async s => {
990- const resource = await fileDialogService . showSaveDialog ( {
991- availableFileSystems : [ Schemas . file ] ,
992- defaultFileName : basename ( s . resource . path )
993- } ) ;
994- if ( resource ) {
995- await textFileService . saveAs ( s . resource , resource ) ;
996- }
989+ await textFileService . saveAs ( s . resource , undefined , { availableFileSystems : [ Schemas . file ] } ) ;
997990 } ) ;
998991 }
999992} ;
0 commit comments