Fix incremental search bug
This commit is contained in:
@@ -137,8 +137,14 @@ export class SearchAddon implements ITerminalAddon {
|
|||||||
|
|
||||||
this._initLinesCache();
|
this._initLinesCache();
|
||||||
|
|
||||||
// Search startRow
|
if (incremental) {
|
||||||
result = incremental ? this._findInLine(term, startRow, startCol, searchOptions, false) : this._findInLine(term, startRow, startCol, searchOptions, isReverseSearch);
|
result = this._findInLine(term, startRow, startCol, searchOptions, false);
|
||||||
|
if (!(result && result.row === startRow && result.col === startCol)) {
|
||||||
|
result = this._findInLine(term, startRow, startCol, searchOptions, true);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
result = this._findInLine(term, startRow, startCol, searchOptions, isReverseSearch);
|
||||||
|
}
|
||||||
|
|
||||||
// Search from startRow - 1 to top
|
// Search from startRow - 1 to top
|
||||||
if (!result) {
|
if (!result) {
|
||||||
|
|||||||
Reference in New Issue
Block a user