add to mockbuffer
This commit is contained in:
+11
-11
@@ -591,12 +591,12 @@ export class Buffer implements IBuffer {
|
||||
*/
|
||||
public clearMarkers(y: number): void {
|
||||
this._isClearing = true;
|
||||
for (let i = 0; i < this.markers.length; i++) {
|
||||
if (this.markers[i].line === y) {
|
||||
this.markers[i].dispose();
|
||||
this.markers.splice(i--, 1);
|
||||
}
|
||||
for (let i = 0; i < this.markers.length; i++) {
|
||||
if (this.markers[i].line === y) {
|
||||
this.markers[i].dispose();
|
||||
this.markers.splice(i--, 1);
|
||||
}
|
||||
}
|
||||
this._isClearing = false;
|
||||
}
|
||||
|
||||
@@ -604,13 +604,13 @@ export class Buffer implements IBuffer {
|
||||
* Clears markers on all lines except for those on a particular line.
|
||||
* @param excludeY The line to exclude.
|
||||
*/
|
||||
public clearAllMarkers(excludeY: number): void {
|
||||
public clearAllMarkers(excludeY: number): void {
|
||||
this._isClearing = true;
|
||||
for (let i = 0; i < this.markers.length; i++) {
|
||||
if (this.markers[i].line !== excludeY) {
|
||||
this.markers[i].dispose();
|
||||
this.markers.splice(i--, 1);
|
||||
}
|
||||
for (let i = 0; i < this.markers.length; i++) {
|
||||
if (this.markers[i].line !== excludeY) {
|
||||
this.markers[i].dispose();
|
||||
this.markers.splice(i--, 1);
|
||||
}
|
||||
}
|
||||
this._isClearing = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user