- activate() within extension.ts is called
- IoC-Container registers the classes we use for dependency injection
- Register the CustomTextEditor
- Register the command for toggling the text editor
- For every
.hexagonfile:- The CustomTextEditor.resolveCustomTextEditor() method is called
- CustomTextEditor calls out/WebviewAdapter and out/DocumentAdapter to set the current webview and the
corresponding
.hexagonfile as the active ones - Create a new in/DocumentAdapter and in/WebviewAdapter
- The in/WebviewAdapter calls SyncDocumentService.sync()
- The SyncDocumentService calls the out/DocumentAdapter
- The out/DocumentAdapter performs validation and uses the currently active document to write the changes to it
- The in/TextEditorAdapter calls TextEditorService.toggle()
- The TextEditorService calls out/TextEditorAdapter
- To load all open text editors
- To open or close the text editor for the currently active
.hexagonfile
- The in/DocumentAdapter calls SyncWebviewService.sync()
- The SyncWebviewService calls the out/WebviewAdapter
- The out/WebviewAdapter performs validation and uses the currently active webview to post a message to it
- The in/TextEditorAdapter calls TextEditorService.close() with all closed
.hexagonfiles - The TextEditorService calls out/TextEditorAdapter
- To load all open text editors
- To close the text editor for the
.hexagonfile(s)
- CustomTextEditor calls out/WebviewAdapter and out/DocumentAdapter to set the new active webview and document
- The in/TextEditorAdapter calls TextEditorService.toggle()
- The TextEditorService calls out/TextEditorAdapter
- To load all open text editors
- To open or close the text editor for the currently active
.hexagonfile