Class ControlPanelAction<T extends ControlPanel>

java.lang.Object
javax.swing.AbstractAction
cz.fidentis.analyst.gui.task.ControlPanelAction<T>
Type Parameters:
T - the type of control panel
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
Direct Known Subclasses:
BatchCuttingPlanesAction, BatchDistanceAction, BatchRegistrationAction, CurvatureAction, CuttingPlanesAction, DistanceAction, FaceOverviewAction, FeaturePointsAction, InteractiveMaskAction, RegistrationAction, SymmetryAction

public abstract class ControlPanelAction<T extends ControlPanel> extends AbstractAction
Default action listener (controller) used to connect specific control panel with the canvas.
See Also:
  • Constructor Details

    • ControlPanelAction

      public ControlPanelAction(Canvas canvas, FacesProxy faces, JTabbedPane topControlPane)
      Constructor.
      Parameters:
      canvas - OpenGL canvas
      faces - Faces processed by current analytical task
      topControlPane - A top component when a new control panel is placed
      Throws:
      IllegalArgumentException - if some param is missing
  • Method Details

    • actionPerformed

      public abstract void actionPerformed(ActionEvent ae)
    • popup

      public void popup()
      Popups (shows) this control panel.
    • getCanvas

      protected Canvas getCanvas()
    • setControlPanel

      protected void setControlPanel(T controlPanel)
      Sets (replaces) the control panel.
      Parameters:
      controlPanel - a control panel
    • getControlPanel

      protected T getControlPanel()
    • setShowHideCode

      protected void setShowHideCode(Runnable visible, Runnable hidden)
      Provide a code that is run when the control panel is focused (popped up, shown) and unfocused (closed or hidden by another control panel)
      Parameters:
      visible - A code to be run when the control panel is focused
      hidden - A code to be run when the control panel hides
    • getFaces

      protected FacesProxy getFaces()
    • getPrimaryFace

      protected HumanFace getPrimaryFace()
      Return the primary face
      Returns:
      the primary face
    • getSecondaryFace

      protected HumanFace getSecondaryFace()
      Return the secondary face
      Returns:
      the secondary face
    • hideShowPanelActionPerformed

      protected void hideShowPanelActionPerformed(ActionEvent ae, ControlPanel controlPanel)
      The generic code for showing/hiding the control panel
      Parameters:
      ae - Action event
    • getScene

      protected Scene getScene()
    • getPrimaryDrawableFace

      protected DrawableFace getPrimaryDrawableFace()
    • getSecondaryDrawableFace

      protected DrawableFace getSecondaryDrawableFace()
    • getPrimaryFeaturePoints

      protected DrawableFeaturePoints getPrimaryFeaturePoints()
    • getSecondaryFeaturePoints

      protected DrawableFeaturePoints getSecondaryFeaturePoints()
    • getPrimaryInteractiveMask

      protected DrawableInteractiveMask getPrimaryInteractiveMask()
    • getSecondaryInteractiveMask

      protected DrawableInteractiveMask getSecondaryInteractiveMask()
    • renderScene

      protected void renderScene()