mirror of
https://github.com/atom/atom.git
synced 2026-01-28 16:28:09 -05:00
Merge branch 'master' into as-double-reflow-measurements
This commit is contained in:
@@ -8,6 +8,7 @@ class DOMElementPool
|
||||
@freedElements.clear()
|
||||
for tagName, freeElements of @freeElementsByTagName
|
||||
freeElements.length = 0
|
||||
return
|
||||
|
||||
build: (tagName, className, textContent = "") ->
|
||||
element = @freeElementsByTagName[tagName]?.pop()
|
||||
@@ -27,6 +28,7 @@ class DOMElementPool
|
||||
for index in [element.children.length - 1..0] by -1
|
||||
child = element.children[index]
|
||||
@freeElementAndDescendants(child)
|
||||
return
|
||||
|
||||
free: (element) ->
|
||||
throw new Error("The element cannot be null or undefined.") unless element?
|
||||
|
||||
Reference in New Issue
Block a user