small cleanup
This commit is contained in:
parent
a4f82e70f6
commit
43bfe515ed
1 changed files with 13 additions and 13 deletions
|
|
@ -264,16 +264,16 @@ var Text = function(parentEl) {
|
||||||
};
|
};
|
||||||
|
|
||||||
this.$renderLinesFragment = function(config, firstRow, lastRow) {
|
this.$renderLinesFragment = function(config, firstRow, lastRow) {
|
||||||
var fragment = this.element.ownerDocument.createDocumentFragment(),
|
var fragment = this.element.ownerDocument.createDocumentFragment();
|
||||||
row = firstRow,
|
var row = firstRow;
|
||||||
fold = this.session.getNextFoldLine(row),
|
var foldLine = this.session.getNextFoldLine(row);
|
||||||
foldStart = fold ?fold.start.row :Infinity;
|
var foldStart = foldLine ? foldLine.start.row : Infinity;
|
||||||
|
|
||||||
while (true) {
|
while (true) {
|
||||||
if (row > foldStart) {
|
if (row > foldStart) {
|
||||||
row = fold.end.row+1;
|
row = foldLine.end.row+1;
|
||||||
fold = this.session.getNextFoldLine(row, fold);
|
foldLine = this.session.getNextFoldLine(row, foldLine);
|
||||||
foldStart = fold ?fold.start.row :Infinity;
|
foldStart = foldLine ? foldLine.start.row : Infinity;
|
||||||
}
|
}
|
||||||
if (row > lastRow)
|
if (row > lastRow)
|
||||||
break;
|
break;
|
||||||
|
|
@ -312,15 +312,15 @@ var Text = function(parentEl) {
|
||||||
var html = [];
|
var html = [];
|
||||||
var firstRow = config.firstRow, lastRow = config.lastRow;
|
var firstRow = config.firstRow, lastRow = config.lastRow;
|
||||||
|
|
||||||
var row = firstRow,
|
var row = firstRow;
|
||||||
fold = this.session.getNextFoldLine(row),
|
var foldLine = this.session.getNextFoldLine(row);
|
||||||
foldStart = fold ?fold.start.row :Infinity;
|
var foldStart = foldLine ? foldLine.start.row : Infinity;
|
||||||
|
|
||||||
while (true) {
|
while (true) {
|
||||||
if (row > foldStart) {
|
if (row > foldStart) {
|
||||||
row = fold.end.row+1;
|
row = foldLine.end.row+1;
|
||||||
fold = this.session.getNextFoldLine(row, fold);
|
foldLine = this.session.getNextFoldLine(row, foldLine);
|
||||||
foldStart = fold ?fold.start.row :Infinity;
|
foldStart = foldLine ? foldLine.start.row :Infinity;
|
||||||
}
|
}
|
||||||
if (row > lastRow)
|
if (row > lastRow)
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue