WIP lsp-manager effort 5
This commit is contained in:
@@ -178,11 +178,6 @@ export class CodeViewBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public closeFile() {
|
public closeFile() {
|
||||||
let message = new ServiceMessage();
|
|
||||||
message.action = "close-file";
|
|
||||||
message.rawData = this.editor.getSession();
|
|
||||||
|
|
||||||
this.lspManagerService.sendMessage(message);
|
|
||||||
this.tabsService.closeTab(this.activeFile.path);
|
this.tabsService.closeTab(this.activeFile.path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -139,6 +139,7 @@ export class EditorsComponent {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
activeComponent.lspManagerService.closeDocument(file.session);
|
||||||
this.filesService.delete(file);
|
this.filesService.delete(file);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -192,7 +193,7 @@ export class EditorsComponent {
|
|||||||
});
|
});
|
||||||
|
|
||||||
window.fs.onUpdateFilePath(async (path: string) => {
|
window.fs.onUpdateFilePath(async (path: string) => {
|
||||||
console.log(path);
|
console.log("TODO (onUpdateFilePath) :", path);
|
||||||
// this.tabsService.sendMessage(message);
|
// this.tabsService.sendMessage(message);
|
||||||
// this.filesService.sendMessage(message);
|
// this.filesService.sendMessage(message);
|
||||||
});
|
});
|
||||||
|
@@ -98,12 +98,12 @@ export class LspManagerComponent {
|
|||||||
|
|
||||||
public registerEditorToLanguageClient() {
|
public registerEditorToLanguageClient() {
|
||||||
this.lspManagerService.registerEditorToLSPClient(this.editor);
|
this.lspManagerService.registerEditorToLSPClient(this.editor);
|
||||||
|
/*
|
||||||
this.lspManagerService.setSessionFilePath(
|
this.lspManagerService.setSessionFilePath(
|
||||||
this.editor.session,
|
this.editor.session,
|
||||||
this.activeFile.path
|
this.activeFile.path
|
||||||
);
|
);
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -139,13 +139,17 @@ export class LspManagerComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private editorUpdate(message: ServiceMessage) {
|
private editorUpdate(message: ServiceMessage) {
|
||||||
|
if (!message.rawData.activeFile) return;
|
||||||
|
|
||||||
this.editor.setSession(message.rawData.editor.getSession())
|
this.editor.setSession(message.rawData.editor.getSession())
|
||||||
this.activeFile = message.rawData.activeFile;
|
this.activeFile = message.rawData.activeFile;
|
||||||
|
|
||||||
|
/*
|
||||||
this.lspManagerService.setSessionFilePath(
|
this.lspManagerService.setSessionFilePath(
|
||||||
this.editor.session,
|
this.editor.session,
|
||||||
this.activeFile.path
|
this.activeFile.path
|
||||||
);
|
);
|
||||||
|
*/
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user