Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fixed renaming and moving of open notebooks #13467

Merged
merged 2 commits into from
Mar 13, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions packages/notebook/src/browser/notebook-editor-widget.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export class NotebookEditorWidget extends ReactWidget implements Navigatable, Sa
}

createMoveToUri(resourceUri: URI): URI | undefined {
return this.props.uri;
return this.model?.uri.withPath(resourceUri.path);
}

undo(): void {
Expand All @@ -199,12 +199,8 @@ export class NotebookEditorWidget extends ReactWidget implements Navigatable, Sa
}
}

protected override onAfterAttach(msg: Message): void {
super.onAfterAttach(msg);
}

protected override onAfterDetach(msg: Message): void {
super.onAfterDetach(msg);
protected override onCloseRequest(msg: Message): void {
super.onCloseRequest(msg);
this.notebookEditorService.removeNotebookEditor(this);
}

Expand Down
Loading