From 19288c4a227d502ca0e39f338c328912a0167aac Mon Sep 17 00:00:00 2001 From: "Enzo Persillet (Tutez)" Date: Sat, 21 Mar 2026 22:04:02 +0100 Subject: [PATCH] Preserve timeline instances from removed-child cleanup --- src/swf/exporters/animate/AnimateTimeline.hx | 1 + src/swf/exporters/swflite/timeline/SymbolTimeline.hx | 1 + 2 files changed, 2 insertions(+) diff --git a/src/swf/exporters/animate/AnimateTimeline.hx b/src/swf/exporters/animate/AnimateTimeline.hx index 5e4046e..199c49e 100644 --- a/src/swf/exporters/animate/AnimateTimeline.hx +++ b/src/swf/exporters/animate/AnimateTimeline.hx @@ -398,6 +398,7 @@ class AnimateTimeline extends Timeline // if (__sprite.stage != null) displayObject.dispatchEvent(new Event(Event.ADDED_TO_STAGE, false, false)); #end + displayObject.__removedChildCleanupDelay = Math.POSITIVE_INFINITY; instance = new FrameSymbolInstance(frame, frameObject.id, frameObject.symbol, frameObject.depth, displayObject, frameObject.clipDepth); diff --git a/src/swf/exporters/swflite/timeline/SymbolTimeline.hx b/src/swf/exporters/swflite/timeline/SymbolTimeline.hx index 4fb5274..58ea15a 100644 --- a/src/swf/exporters/swflite/timeline/SymbolTimeline.hx +++ b/src/swf/exporters/swflite/timeline/SymbolTimeline.hx @@ -234,6 +234,7 @@ class SymbolTimeline extends Timeline // displayObject.stage = __movieClip.stage; // if (__movieClip.stage != null) displayObject.dispatchEvent(new Event(Event.ADDED_TO_STAGE, false, false)); + displayObject.__removedChildCleanupDelay = Math.POSITIVE_INFINITY; instance = new FrameSymbolInstance(frame, frameObject.id, frameObject.symbol, frameObject.depth, displayObject, frameObject.clipDepth);