File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
arduino-ide-extension/src/browser Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -70,6 +70,7 @@ import { SaveAsSketch } from './contributions/save-as-sketch';
7070import { SketchbookWidgetContribution } from './widgets/sketchbook/sketchbook-widget-contribution' ;
7171import { IDEUpdaterDialog } from './dialogs/ide-updater/ide-updater-dialog' ;
7272import { IDEUpdater } from '../common/protocol/ide-updater' ;
73+ import { FileSystemFrontendContribution } from '@theia/filesystem/lib/browser/filesystem-frontend-contribution' ;
7374
7475const INIT_LIBS_AND_PACKAGES = 'initializedLibsAndPackages' ;
7576export const SKIP_IDE_VERSION = 'skipIDEVersion' ;
@@ -159,6 +160,9 @@ export class ArduinoFrontendContribution
159160 @inject ( LocalStorageService )
160161 protected readonly localStorageService : LocalStorageService ;
161162
163+ @inject ( FileSystemFrontendContribution )
164+ protected readonly fileSystemFrontendContribution : FileSystemFrontendContribution ;
165+
162166 @inject ( IDEUpdater )
163167 protected readonly updater : IDEUpdater ;
164168
@@ -337,6 +341,12 @@ export class ArduinoFrontendContribution
337341 } ) ;
338342
339343 app . shell . leftPanelHandler . removeBottomMenu ( 'settings-menu' ) ;
344+
345+ this . fileSystemFrontendContribution . onDidChangeEditorFile ( e => {
346+ if ( e . type === FileChangeType . DELETED ) {
347+ e . editor . close ( ) ;
348+ }
349+ } ) ;
340350 }
341351
342352 onStop ( ) : void {
You can’t perform that action at this time.
0 commit comments