mirror of
https://github.com/atom/atom.git
synced 2026-04-06 03:02:13 -04:00
Don't use atom globals in LinesComponent
This commit is contained in:
committed by
Nathan Sobo
parent
6fed847cce
commit
eba18092fb
@@ -13,7 +13,7 @@ cloneObject = (object) ->
|
||||
|
||||
module.exports =
|
||||
class LinesTileComponent
|
||||
constructor: ({@presenter, @id, @domElementPool}) ->
|
||||
constructor: ({@presenter, @id, @domElementPool, @assert}) ->
|
||||
@tokenIterator = new TokenIterator
|
||||
@measuredLines = new Set
|
||||
@lineNodesByLineId = {}
|
||||
@@ -361,7 +361,7 @@ class LinesTileComponent
|
||||
rangeForMeasurement.setEnd(textNode, i + charLength)
|
||||
else
|
||||
rangeForMeasurement.setEnd(textNode, textNodeLength)
|
||||
atom.assert false, "Expected index to be less than the length of text node while measuring", (error) =>
|
||||
@assert false, "Expected index to be less than the length of text node while measuring", (error) =>
|
||||
editor = @presenter.model
|
||||
screenRow = tokenizedLine.screenRow
|
||||
bufferRow = editor.bufferRowForScreenRow(screenRow)
|
||||
|
||||
Reference in New Issue
Block a user