package sc.iview.ui;

import graphics.scenery.Node;

import javax.swing.*;

public class ContextPopUp extends JPopupMenu {

    JMenuItem anItem;
    public ContextPopUp(Node n) {
        anItem = new JMenuItem("I'm a " + n.getNodeType());
        add(anItem);
    }

}

@@ -121,30 +121,8 @@
  %7B%0A%0A
-    JMenuItem anItem;%0A
     
@@ -164,15 +164,11 @@
    a
-nItem =
+dd(
  new
@@ -183,13 +183,13 @@
 em(%22
-I'm a
+Name:
  %22 +
@@ -199,18 +199,16 @@
 getN
-odeTyp
+am
 e())
+ )
 ;%0A  
@@ -221,14 +221,51 @@
 add(
-anItem
+ new JMenuItem(%22Type: %22 + n.getNodeType()) 
 );%0A 

Make context menu look a little more reasonable