create dom elements only for visible cursors
This commit is contained in:
parent
eab6061282
commit
c54da935ab
1 changed files with 4 additions and 0 deletions
|
|
@ -148,6 +148,10 @@ var Cursor = function(parentEl) {
|
|||
for (var i = selections.length; i--; ) {
|
||||
sel = selections[i];
|
||||
var pixelPos = this.getPixelPosition(sel.cursor, true);
|
||||
if ((pixelPos.top > config.height + config.offset ||
|
||||
pixelPos.top < -config.offset) && i > 1) {
|
||||
continue;
|
||||
}
|
||||
|
||||
var style = (this.cursors[cursorIndex++] || this.addCursor()).style;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue