mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 21:09:43 +00:00
Remove hack for canvas to force a refresh
I can no longer reproduce this issue and it was a big hack regardless. Will track issues for any mentioned of bad resizes on the canvas renderer.
This commit is contained in:
parent
64aa2c302f
commit
ee7fe25638
|
@ -1859,10 +1859,6 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
|
||||||
|
|
||||||
this.xterm.raw.resize(cols, rows);
|
this.xterm.raw.resize(cols, rows);
|
||||||
TerminalInstance._lastKnownGridDimensions = { cols, rows };
|
TerminalInstance._lastKnownGridDimensions = { cols, rows };
|
||||||
|
|
||||||
if (this._isVisible) {
|
|
||||||
this.xterm.forceUnpause();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (immediate) {
|
if (immediate) {
|
||||||
|
|
|
@ -31,6 +31,5 @@ export interface IXtermCore {
|
||||||
_renderLayers?: any[];
|
_renderLayers?: any[];
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
_handleIntersectionChange: any;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -446,19 +446,6 @@ export class XtermTerminal extends Disposable implements IXtermTerminal, IDetach
|
||||||
this._core.viewport?._innerRefresh();
|
this._core.viewport?._innerRefresh();
|
||||||
}
|
}
|
||||||
|
|
||||||
forceUnpause() {
|
|
||||||
// HACK: Force the renderer to unpause by simulating an IntersectionObserver event.
|
|
||||||
// This is to fix an issue where dragging the windpow to the top of the screen to
|
|
||||||
// maximize on Windows/Linux would fire an event saying that the terminal was not
|
|
||||||
// visible.
|
|
||||||
if (!!this._canvasAddon) {
|
|
||||||
this._core._renderService?._handleIntersectionChange({ intersectionRatio: 1 });
|
|
||||||
// HACK: Force a refresh of the screen to ensure links are refresh corrected.
|
|
||||||
// This can probably be removed when the above hack is fixed in Chromium.
|
|
||||||
this.raw.refresh(0, this.raw.rows - 1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async findNext(term: string, searchOptions: ISearchOptions): Promise<boolean> {
|
async findNext(term: string, searchOptions: ISearchOptions): Promise<boolean> {
|
||||||
this._updateFindColors(searchOptions);
|
this._updateFindColors(searchOptions);
|
||||||
return (await this._getSearchAddon()).findNext(term, searchOptions);
|
return (await this._getSearchAddon()).findNext(term, searchOptions);
|
||||||
|
|
Loading…
Reference in a new issue