Package cz.fidentis.analyst.gui.task
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
Default action listener (controller) used to connect specific control panel
with the canvas.
- See Also:
-
Field Summary
Fields inherited from class javax.swing.AbstractAction
enabled, changeSupport
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
-
Constructor Summary
ConstructorsConstructorDescriptionControlPanelAction
(Canvas canvas, FacesProxy faces, JTabbedPane topControlPane) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionabstract void
protected Canvas
protected T
protected FacesProxy
getFaces()
protected DrawableFace
protected HumanFace
Return the primary faceprotected DrawableFeaturePoints
protected DrawableInteractiveMask
protected Scene
getScene()
protected DrawableFace
protected HumanFace
Return the secondary faceprotected DrawableFeaturePoints
protected DrawableInteractiveMask
protected void
hideShowPanelActionPerformed
(ActionEvent ae, ControlPanel controlPanel) The generic code for showing/hiding the control panelvoid
popup()
Popups (shows) this control panel.protected void
protected void
setControlPanel
(T controlPanel) Sets (replaces) the control panel.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)Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
Constructor Details
-
ControlPanelAction
Constructor.- Parameters:
canvas
- OpenGL canvasfaces
- Faces processed by current analytical tasktopControlPane
- A top component when a new control panel is placed- Throws:
IllegalArgumentException
- if some param is missing
-
-
Method Details
-
actionPerformed
-
popup
public void popup()Popups (shows) this control panel. -
getCanvas
-
setControlPanel
Sets (replaces) the control panel.- Parameters:
controlPanel
- a control panel
-
getControlPanel
-
setShowHideCode
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 focusedhidden
- A code to be run when the control panel hides
-
getFaces
-
getPrimaryFace
Return the primary face- Returns:
- the primary face
-
getSecondaryFace
Return the secondary face- Returns:
- the secondary face
-
hideShowPanelActionPerformed
The generic code for showing/hiding the control panel- Parameters:
ae
- Action event
-
getScene
-
getPrimaryDrawableFace
-
getSecondaryDrawableFace
-
getPrimaryFeaturePoints
-
getSecondaryFeaturePoints
-
getPrimaryInteractiveMask
-
getSecondaryInteractiveMask
-
renderScene
protected void renderScene()
-