Fix LayoutCoordinates reference leaks in #101
This commit is contained in:
1 parent
27baa2034b
commit
7c37be469a
2 files changed
+8
-2
No files matched your search
@@ -176,7 +176,10 @@ private class DrawBackdropElement(
|
||||
node.shapeProvider = shapeProvider
|
||||
node.effects = effects
|
||||
node.layerBlock = layerBlock
|
||||
node.exportedBackdrop = exportedBackdrop
|
||||
if (node.exportedBackdrop != exportedBackdrop) {
|
||||
node.exportedBackdrop?.layerCoordinates = null
|
||||
node.exportedBackdrop = exportedBackdrop
|
||||
}
|
||||
node.onDrawBehind = onDrawBehind
|
||||
node.onDrawBackdrop = onDrawBackdrop
|
||||
node.onDrawSurface = onDrawSurface
|
||||
|
||||
+4
-1
@@ -22,7 +22,10 @@ private class LayerBackdropElement(
|
||||
}
|
||||
|
||||
override fun update(node: LayerBackdropNode) {
|
||||
node.backdrop = backdrop
|
||||
if (node.backdrop != backdrop) {
|
||||
node.backdrop.layerCoordinates = null
|
||||
node.backdrop = backdrop
|
||||
}
|
||||
node.invalidateDraw()
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user