Skip to content

Commit

Permalink
Avoid extra work when lightbulb is already hidden
Browse files Browse the repository at this point in the history
Part of #161622
  • Loading branch information
Tyriar committed Oct 17, 2022
1 parent 148347c commit cff25b7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/vs/editor/contrib/codeAction/browser/lightBulbWidget.ts
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,9 @@ export class LightBulbWidget extends Disposable implements IContentWidget {
}

public hide(): void {
if (this.state === LightBulbState.Hidden) {
return;
}
this.state = LightBulbState.Hidden;
this._editor.layoutContentWidget(this);
}
Expand Down

0 comments on commit cff25b7

Please sign in to comment.