Correctly store which lines we have already measured

This commit is contained in:
Nathan Sobo
2015-02-23 17:18:53 -08:00
parent 7456bcfb98
commit 622caee446

View File

@@ -277,10 +277,10 @@ class LinesComponent
for id, lineState of @oldState.lines
unless @measuredLines.has(id)
lineNode = @lineNodesByLineId[id]
@measureCharactersInLine(lineState, lineNode)
@measureCharactersInLine(id, lineState, lineNode)
return
measureCharactersInLine: (tokenizedLine, lineNode) ->
measureCharactersInLine: (lineId, tokenizedLine, lineNode) ->
rangeForMeasurement = null
iterator = null
charIndex = 0
@@ -322,7 +322,7 @@ class LinesComponent
charIndex += charLength
@measuredLines.add(tokenizedLine.id)
@measuredLines.add(lineId)
clearScopedCharWidths: ->
@measuredLines.clear()