From d8e512368f913b28cb2e2adb89243f602e1b463a Mon Sep 17 00:00:00 2001 From: Samuel Pantze <83579186+smlpt@users.noreply.github.com> Date: Tue, 23 Apr 2024 18:01:12 +0200 Subject: [PATCH] fix: removed nodeType dependency on scenery --- src/main/java/sc/iview/commands/file/ExportN5.java | 2 +- src/main/kotlin/sc/iview/SciView.kt | 2 +- src/main/kotlin/sc/iview/ui/ContextPopUp.kt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/sc/iview/commands/file/ExportN5.java b/src/main/java/sc/iview/commands/file/ExportN5.java index ee3a7488..ec1f59cb 100644 --- a/src/main/java/sc/iview/commands/file/ExportN5.java +++ b/src/main/java/sc/iview/commands/file/ExportN5.java @@ -91,7 +91,7 @@ public void run() { } } else { - logService.warn("Node is " + sciView.getActiveNode().getNodeType() + " cannot export to N5."); + logService.warn("Node is " + sciView.getActiveNode().getClass() + " cannot export to N5."); } } diff --git a/src/main/kotlin/sc/iview/SciView.kt b/src/main/kotlin/sc/iview/SciView.kt index 27431421..346eb46f 100644 --- a/src/main/kotlin/sc/iview/SciView.kt +++ b/src/main/kotlin/sc/iview/SciView.kt @@ -1814,7 +1814,7 @@ class SciView : SceneryBase, CalibratedRealInterval { * Convenience function for getting a string of info about a Node */ fun nodeInfoString(n: Node): String { - return "Node name: " + n.name + " Node type: " + n.nodeType + " To String: " + n + return "Node name: " + n.name + " Node type: " + n.javaClass + " To String: " + n } /** diff --git a/src/main/kotlin/sc/iview/ui/ContextPopUp.kt b/src/main/kotlin/sc/iview/ui/ContextPopUp.kt index a2886570..e2413c01 100644 --- a/src/main/kotlin/sc/iview/ui/ContextPopUp.kt +++ b/src/main/kotlin/sc/iview/ui/ContextPopUp.kt @@ -35,6 +35,6 @@ import javax.swing.JPopupMenu class ContextPopUp(n: Node) : JPopupMenu() { init { add(JMenuItem("Name: " + n.name)) - add(JMenuItem("Type: " + n.nodeType)) + add(JMenuItem("Type: " + n.javaClass)) } }