mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-22 08:28:41 +03:00
Don't tokenize files that have more than 10000 lines
This commit is contained in:
parent
840efa3d82
commit
987d1da233
@ -62,8 +62,11 @@ class TokenizedBuffer
|
||||
@invalidateRow(0)
|
||||
@trigger "changed", { start: 0, end: lastRow, delta: 0 }
|
||||
|
||||
tooBigToTokenize: ->
|
||||
@screenLines.length > 10000
|
||||
|
||||
tokenizeInBackground: ->
|
||||
return if not @visible or @pendingChunk
|
||||
return if not @visible or @pendingChunk or @tooBigToTokenize()
|
||||
@pendingChunk = true
|
||||
_.defer =>
|
||||
@pendingChunk = false
|
||||
|
Loading…
Reference in New Issue
Block a user