Skip to content

Commit

Permalink
Merge pull request #525 from scenerygraphics/node-deletion
Browse files Browse the repository at this point in the history
  • Loading branch information
kephale authored Jul 16, 2023
2 parents 32407ec + 8536e62 commit 64fdc07
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/kotlin/sc/iview/SciView.kt
Original file line number Diff line number Diff line change
Expand Up @@ -1176,7 +1176,7 @@ class SciView : SceneryBase, CalibratedRealInterval<CalibratedAxis> {
* @param activePublish whether the deletion should be published
*/
@JvmOverloads
fun deleteNode(node: Node?, activePublish: Boolean = true) {
fun deleteNode(node: Node?, activePublish: Boolean = true) {
if(node is Volume) {
node.volumeManager.remove(node)
val toRemove = ArrayList<Any>()
Expand Down Expand Up @@ -1210,7 +1210,7 @@ fun deleteNode(node: Node?, activePublish: Boolean = true) {
fun dispose() {
val objs: List<Node> = objectService.getObjects(Node::class.java)
for (obj in objs) {
objectService.removeObject(obj)
deleteNode(obj, activePublish = false)
}
scijavaContext!!.service(SciViewService::class.java).close(this)
close()
Expand Down

0 comments on commit 64fdc07

Please sign in to comment.