diff --git a/packages/scm/src/browser/scm-amend-widget.tsx b/packages/scm/src/browser/scm-amend-widget.tsx index e9ea1c16fa47c..296563f9c9fc1 100644 --- a/packages/scm/src/browser/scm-amend-widget.tsx +++ b/packages/scm/src/browser/scm-amend-widget.tsx @@ -15,7 +15,6 @@ ********************************************************************************/ import { injectable, inject } from 'inversify'; -import { Message } from '@phosphor/messaging'; import { SelectionService } from '@theia/core/lib/common'; import * as React from 'react'; import { @@ -51,13 +50,6 @@ export class ScmAmendWidget extends ReactWidget { this.id = ScmAmendWidget.ID; } - protected onUpdateRequest(msg: Message): void { - if (!this.isAttached || !this.isVisible) { - return; - } - super.onUpdateRequest(msg); - } - protected render(): React.ReactNode { const repository = this.scmService.selectedRepository; if (repository && repository.provider.amendSupport) { diff --git a/packages/scm/src/browser/scm-commit-widget.tsx b/packages/scm/src/browser/scm-commit-widget.tsx index b636795da9070..16ba4119f8eae 100644 --- a/packages/scm/src/browser/scm-commit-widget.tsx +++ b/packages/scm/src/browser/scm-commit-widget.tsx @@ -16,12 +16,11 @@ import { injectable, inject } from 'inversify'; import { Message } from '@phosphor/messaging'; -import { SelectionService } from '@theia/core/lib/common'; import * as React from 'react'; import TextareaAutosize from 'react-autosize-textarea'; import { ScmInput } from './scm-input'; import { - ContextMenuRenderer, ReactWidget, LabelProvider, KeybindingRegistry, StatefulWidget} from '@theia/core/lib/browser'; + ContextMenuRenderer, ReactWidget, KeybindingRegistry, StatefulWidget} from '@theia/core/lib/browser'; import { ScmService } from './scm-service'; @injectable() @@ -30,8 +29,6 @@ export class ScmCommitWidget extends ReactWidget implements StatefulWidget { static ID = 'scm-commit-widget'; @inject(ScmService) protected readonly scmService: ScmService; - @inject(SelectionService) protected readonly selectionService: SelectionService; - @inject(LabelProvider) protected readonly labelProvider: LabelProvider; @inject(KeybindingRegistry) protected readonly keybindings: KeybindingRegistry; protected shouldScrollToRow = true; @@ -60,13 +57,6 @@ export class ScmCommitWidget extends ReactWidget implements StatefulWidget { (this.inputRef.current || this.node).focus(); } - protected onUpdateRequest(msg: Message): void { - if (!this.isAttached || !this.isVisible) { - return; - } - super.onUpdateRequest(msg); - } - protected render(): React.ReactNode { const repository = this.scmService.selectedRepository; if (repository) { diff --git a/packages/scm/src/browser/scm-widget.tsx b/packages/scm/src/browser/scm-widget.tsx index 09c35c4148082..3079ba52b01f0 100644 --- a/packages/scm/src/browser/scm-widget.tsx +++ b/packages/scm/src/browser/scm-widget.tsx @@ -130,9 +130,6 @@ export class ScmWidget extends BaseWidget implements StatefulWidget { } protected onUpdateRequest(msg: Message): void { - if (!this.isAttached || !this.isVisible) { - return; - } MessageLoop.sendMessage(this.commitWidget, msg); MessageLoop.sendMessage(this.resourceWidget, msg); MessageLoop.sendMessage(this.amendWidget, msg);