trevordevore / levure

Application development framework for LiveCode
MIT License
32 stars 14 forks source link

Remove behaviors listed in stackfiles when closing a ui stack with destroystack set to true #124

Open trevordevore opened 5 years ago

trevordevore commented 5 years ago

When closing a ui stack which has destroyStack set to true Levure should remove all of the behaviors from memory as well. The behaviors should only be removed, however, if no other open stacks are referencing the behavior.

LiveCode 9 added the revbehaviourses function. It takes a reference to an object and returns an array list of object long IDs for objects that are using a behavior.

PR for revBehaviorUses: https://github.com/livecode/livecode/pull/5788