Skip to content

Commit

Permalink
Removed deprecated activateTerminal #10521
Browse files Browse the repository at this point in the history
  • Loading branch information
abhisharsinha authored and vince-fugnitto committed Dec 13, 2021
1 parent aff706d commit 3e0b867
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 13 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
- add `isSafeToShutDown()` - replaces `canUnload()`.
- add `setSafeToShutDown()` - ensures that next close event will not be prevented.
- add `reload()` - to allow different handling in Electron and browser.
- [terminal] removed deprecated `activateTerminal` method in favor of `open`. [#10529](https://github.com/eclipse-theia/theia/pull/10529)

## v1.20.0 - 11/25/2021

Expand Down
2 changes: 1 addition & 1 deletion packages/task/src/browser/task-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1056,7 +1056,7 @@ export class TaskService implements TaskConfigurationClient {
if (!terminal || terminal.kind !== 'user' || (await terminal.hasChildProcesses())) {
terminal = <TerminalWidget>await this.terminalService.newTerminal(<TerminalWidgetFactoryOptions>{ created: new Date().toString() });
await terminal.start();
this.terminalService.activateTerminal(terminal);
this.terminalService.open(terminal);
}
terminal.sendText(selectedText);
}
Expand Down
7 changes: 0 additions & 7 deletions packages/terminal/src/browser/base/terminal-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,6 @@ export interface TerminalService {
*/
newTerminal(options: TerminalWidgetOptions): Promise<TerminalWidget>;

/**
* Display new terminal widget.
* @param terminal - widget to attach.
* @deprecated use #open
*/
activateTerminal(terminal: TerminalWidget): void;

open(terminal: TerminalWidget, options?: WidgetOpenerOptions): void;

readonly all: TerminalWidget[];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ export class TerminalFrontendContribution implements FrontendApplicationContribu
// Open terminal
const termWidget = await this.newTerminal({ cwd });
termWidget.start();
this.activateTerminal(termWidget);
this.open(termWidget);
}

registerMenus(menus: MenuModelRegistry): void {
Expand Down Expand Up @@ -602,10 +602,6 @@ export class TerminalFrontendContribution implements FrontendApplicationContribu
return widget;
}

activateTerminal(widget: TerminalWidget, widgetOptions?: ApplicationShell.WidgetOptions): void {
this.open(widget, { widgetOptions });
}

// TODO: reuse WidgetOpenHandler.open
open(widget: TerminalWidget, options?: WidgetOpenerOptions): void {
const op: WidgetOpenerOptions = {
Expand Down

0 comments on commit 3e0b867

Please sign in to comment.