Class JDialogAddNode

All Implemented Interfaces:
DialogDefaultsInterface, ActionListener, FocusListener, ItemListener, WindowListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, RootPaneContainer, WindowConstants

public class JDialogAddNode extends JDialogBase implements ActionListener
Dialog used by the MipavGraphPanel to add a node to the graph, or to modify the Notes attribute of a node.
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • DEFAULT_NOTES

      public static final String DEFAULT_NOTES
      Default notes section text
      See Also:
    • buttonPanel

      private JPanel buttonPanel
      Panel to contain the okay/cancel/help buttons.
    • nameField

      private JTextField nameField
      NameField that will contain the string to be displayed.
    • noteField

      private JTextArea noteField
      NoteField for providing a note about this marker. Note only displayed when clicked.
    • parent

      private MipavGraphPanel parent
      Parent graph panel to update on 'OK'
    • notes

      private String notes
      Current notes for the node.
    • addNode

      private boolean addNode
      When true the dialog creates a new node, otherwise it is used to edit the Notes.
    • pickedNode

      private hypergraph.graphApi.Node pickedNode
  • Constructor Details

    • JDialogAddNode

      public JDialogAddNode(MipavGraphPanel kParent, String kNotes, boolean bAdd)
    • JDialogAddNode

      public JDialogAddNode(MipavGraphPanel kParent, hypergraph.graphApi.Node pickedNode, String kNotes, boolean bAdd, boolean setVisible)
  • Method Details

    • actionPerformed

      public void actionPerformed(ActionEvent event)
      Catches action events: Okay, Cancel. *
      Specified by:
      actionPerformed in interface ActionListener
      Overrides:
      actionPerformed in class JDialogBase
      Parameters:
      event - ActionEvent
    • getNameField

      public JTextField getNameField()
    • getNoteField

      public JTextArea getNoteField()
    • getNotes

      public String getNotes()
    • init

      private void init(String title)
      Initializes the dialog box and adds the components.
      Parameters:
      title - Title of the dialog box.