Class ConditionalEditFrame
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- java.awt.Window
-
- java.awt.Frame
-
- javax.swing.JFrame
-
- jmri.util.JmriJFrame
-
- jmri.jmrit.conditional.ConditionalFrame
-
- jmri.jmrit.conditional.ConditionalEditFrame
-
- All Implemented Interfaces:
java.awt.event.ComponentListener
,java.awt.event.WindowListener
,java.awt.image.ImageObserver
,java.awt.MenuContainer
,java.io.Serializable
,java.util.EventListener
,javax.accessibility.Accessible
,javax.swing.RootPaneContainer
,javax.swing.WindowConstants
,BeanInterface
,ModifiedFlag
,WindowInterface
public class ConditionalEditFrame extends ConditionalFrame
Extracted from ConditionalEditList. Allows ConditionalEditList to open alternate frame for copying Conditionals.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
ConditionalEditFrame.ActionTableModel
Table model for Actions in Edit Conditional pane.(package private) class
ConditionalEditFrame.ActionTypeListener
Listener for _actionTypeBox.class
ConditionalEditFrame.VariableTableModel
Table model for State Variables in Edit Conditional pane.-
Nested classes/interfaces inherited from class jmri.util.JmriJFrame
JmriJFrame.ScreenDimensions
-
Nested classes/interfaces inherited from class javax.swing.JFrame
javax.swing.JFrame.AccessibleJFrame
-
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow, java.awt.Window.Type
-
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
-
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
-
Nested classes/interfaces inherited from interface jmri.util.swing.WindowInterface
WindowInterface.Hint
-
-
Field Summary
Fields Modifier and Type Field Description (package private) javax.swing.JComboBox<java.lang.String>
_actionBox
(package private) javax.swing.JPanel
_actionComboNamePanel
(package private) javax.swing.JComboBox<Conditional.ItemType>
_actionItemBox
(package private) javax.swing.JTextField
_actionNameField
(package private) javax.swing.JPanel
_actionNamePanel
(package private) javax.swing.JComboBox<java.lang.String>
_actionOptionBox
(package private) javax.swing.JPanel
_actionPanel
(package private) ConditionalEditFrame.ActionTableModel
_actionTableModel
(package private) javax.swing.JComboBox<Conditional.Action>
_actionTypeBox
(package private) ConditionalEditFrame.ActionTypeListener
_actionTypeListener
(package private) javax.swing.JPanel
_actionTypePanel
(package private) javax.swing.JComboBox<java.lang.String>
_andOperatorBox
(package private) javax.swing.JTextField
_antecedentField
(package private) javax.swing.JPanel
_antecedentPanel
(package private) NamedBeanComboBox<?>
_comboNameBox
(package private) ConditionalAction
_curAction
(package private) Conditional.ItemType
_curActionItem
(package private) int
_curActionRowNumber
(package private) ConditionalVariable
_curVariable
(package private) Conditional.ItemType
_curVariableItem
(package private) int
_curVariableRowNumber
(package private) JmriJFrame
_editActionFrame
(package private) JmriJFrame
_editVariableFrame
(package private) boolean
_inActReorder
(package private) boolean
_inVarReorder
(package private) javax.swing.JTextField
_longActionString
(package private) boolean
_newItem
(package private) int
_nextInOrder
(package private) javax.swing.JComboBox<java.lang.String>
_notOperatorBox
(package private) javax.swing.JComboBox<Conditional.AntecedentOperator>
_operatorBox
(package private) javax.swing.JPanel
_optionPanel
(package private) javax.swing.JButton
_reorderVarButton
(package private) javax.swing.JComboBox<java.lang.String>
_selectConditionalBox
(package private) java.util.ArrayList<java.lang.String>
_selectConditionalList
(package private) javax.swing.JPanel
_selectConditionalPanel
(package private) javax.swing.JComboBox<java.lang.String>
_selectLogixBox
(package private) java.util.TreeMap<java.lang.String,java.lang.String>
_selectLogixMap
(package private) javax.swing.JPanel
_selectLogixPanel
(package private) javax.swing.JPanel
_setPanel
(package private) javax.swing.JTextField
_shortActionString
(package private) javax.swing.JPanel
_shortTextPanel
(package private) javax.swing.JPanel
_textPanel
(package private) javax.swing.JRadioButton
_triggerOnChangeButton
(package private) javax.swing.JPanel
_variableComboNamePanel
(package private) javax.swing.JComboBox<java.lang.String>
_variableCompareOpBox
(package private) javax.swing.JPanel
_variableComparePanel
(package private) javax.swing.JComboBox<Conditional.Type>
_variableCompareTypeBox
(package private) javax.swing.JTextField
_variableData1Field
(package private) javax.swing.JPanel
_variableData1Panel
(package private) javax.swing.JTextField
_variableData2Field
(package private) javax.swing.JPanel
_variableData2Panel
(package private) javax.swing.JComboBox<Conditional.ItemType>
_variableItemBox
(package private) javax.swing.JTextField
_variableNameField
(package private) javax.swing.JPanel
_variableNamePanel
(package private) javax.swing.JComboBox<java.lang.String>
_variableSignalBox
(package private) javax.swing.JPanel
_variableSignalPanel
(package private) javax.swing.JComboBox<Conditional.Type>
_variableStateBox
(package private) javax.swing.JPanel
_variableStatePanel
(package private) ConditionalEditFrame.VariableTableModel
_variableTableModel
(package private) java.awt.event.ActionListener
actionSignalHeadNameListener
(package private) java.awt.event.ActionListener
actionSignalMastNameListener
(package private) javax.swing.JFileChooser
defaultFileChooser
(package private) ScriptFileChooser
scriptFileChooser
(package private) java.awt.event.ActionListener
selectConditionalBoxListener
(package private) java.awt.event.ActionListener
selectLogixBoxListener
(package private) javax.swing.JFileChooser
sndFileChooser
(package private) java.awt.event.ActionListener
variableSignalHeadNameListener
(package private) java.awt.event.ActionListener
variableSignalMastNameListener
(package private) java.awt.event.ActionListener
variableSignalTestStateListener
-
Fields inherited from class jmri.jmrit.conditional.ConditionalFrame
_actionList, _antecedent, _conditionalUserName, _dataChanged, _logicType, _parent, _referenceByMemory, _trigger, _variableList, STRUT
-
Fields inherited from class jmri.util.JmriJFrame
allowInFrameServlet, properties, reuseFrameSavedPosition, reuseFrameSavedSized, windowInterface
-
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
-
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
-
-
Constructor Summary
Constructors Constructor Description ConditionalEditFrame(java.lang.String title, Conditional conditional, ConditionalList parent)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
actionItemChanged(Conditional.ItemType type)
Respond to a change in an Action Type comboBox on the Edit Conditional Action pane.(package private) void
addActionPressed(java.awt.event.ActionEvent e)
Respond to Add action button in the EditConditional window.(package private) void
addVariablePressed(java.awt.event.ActionEvent e)
Respond to the Add State Variable Button in the Edit Conditional window.(package private) boolean
alreadyEditingActionOrVariable()
Check if an editing session is going on.(package private) void
appendToAntecedent()
Add a R# to the antecedent statement.(package private) void
cancelConditionalPressed()
Respond to the Cancel button in the Edit Conditional frame.(package private) void
cancelEditActionPressed()
Respond to Cancel action button and window closer of the Edit Action window.(package private) void
cancelEditVariablePressed()
Respond to Cancel action button and window closer of the Edit Variable pane.(package private) void
checkVariablePressed(java.awt.event.ActionEvent e)
Respond to the Check State Variable Button in the Edit Conditional window.(package private) void
cleanUpAction()
Clean up Update and Delete Action buttons.(package private) void
cleanUpVariable()
Clean up Update and Delete Variable buttons.(package private) void
deleteActionPressed()
Respond to Delete action button in the Edit Action window.(package private) void
deleteActionPressed(int row)
Respond to Delete action button in an action row of the Edit Conditional pane.(package private) void
deleteVariablePressed()
Respond to Delete action button in the Edit Variable window.(package private) void
deleteVariablePressed(int row)
Respond to the Delete Button in the State Variable Table of the Edit Conditional window.(package private) void
helpPressed(java.awt.event.ActionEvent e)
Respond to Help button press in the Edit Conditional pane.(package private) void
initializeActionVariables()
Set display to show current action (curAction) parameters.(package private) void
initializeStateVariables()
Set display to show current state variable (_curVariable) parameters.(package private) void
loadJComboBoxWithHeadAppearances(javax.swing.JComboBox<java.lang.String> box, java.lang.String signalHeadName)
Fetch valid localized appearances for a given Signal Head.(package private) void
loadJComboBoxWithMastAspects(javax.swing.JComboBox<java.lang.String> box, java.lang.String mastName)
Fetch valid aspects for a given Signal Mast.(package private) void
loadSelectConditionalBox(java.lang.String logixName, ConditionalVariable curVariable)
Load the Conditional selection box.(package private) void
loadSelectLogixBox(ConditionalVariable curVariable)
Load the Logix selection box.(package private) boolean
logicTypeChanged(java.awt.event.ActionEvent e)
Respond to a change of Conditional Type in the Edit Conditional pane by showing/hiding the _antecedentPanel when Mixed is selected.(package private) void
makeAntecedent()
Build the antecedent statement.(package private) javax.swing.JPanel
makeButtonPanel(java.awt.event.ActionListener updateListener, java.awt.event.ActionListener cancelListener, java.awt.event.ActionListener deleteListener)
Create Variable and Action editing pane bottom part.(package private) void
makeConditionalFrame(Conditional conditional)
(package private) void
makeEditActionWindow(int row)
Create and/or initialize the Edit Action window.(package private) void
makeEditVariableWindow(int row)
Create and/or initialize the Edit a Variable pane.(package private) javax.swing.JPanel
makeTopPanel(javax.swing.JFrame frame, java.lang.String title, int width, int height)
Create Variable and Action editing pane top part.(package private) void
reorderActionPressed(java.awt.event.ActionEvent e)
Respond to the Reorder Action Button in the Edit Conditional window.(package private) void
reorderVariablePressed(java.awt.event.ActionEvent e)
Respond to the Reorder Variable Button in the Edit Conditional window.(package private) void
setActionNameBox(Conditional.ItemType itemType)
Update the name combo box selection based on the current contents of the name field.(package private) void
setFileLocation(java.awt.event.ActionEvent e)
Respond to the [...] button in the Edit Action window action section.(package private) void
setVariableNameBox(Conditional.ItemType itemType)
Update the name combo box selection based on the current contents of the name field.(package private) void
swapActions(int row)
Respond to the First/Next (Delete) Button in the Edit Conditional window.(package private) void
swapVariables(int row)
Respond to the First/Next (Delete) Button in the Edit Conditional window.(package private) void
updateActionPressed()
Respond to Update Action button in the Edit Action pane.(package private) boolean
updateConditionalPressed(java.awt.event.ActionEvent e)
Respond to the Update Conditional Button in the Edit Conditional window.(package private) void
updateVariablePressed()
Respond to Update Variable button in the Edit Action pane.(package private) boolean
validateAction()
Validate Action data from Edit Action Window, and transfer it to current action object as appropriate.(package private) boolean
validateAntecedent()
Check the antecedent and logic type.(package private) boolean
validateVariable()
Validate Variable data from Edit Variable Window, and transfer it to current action object as appropriate.(package private) void
variableNegationChanged(int row, java.lang.String oper)
Respond to the Negation column in the Edit Conditional window.(package private) void
variableOperatorChanged(int row, java.lang.String oper)
Respond to the Operator column in the Edit Conditional window.-
Methods inherited from class jmri.jmrit.conditional.ConditionalFrame
checkIsAction, checkIsVariable, checkReferenceByMemory, makeEditPanel, makeTopPanel
-
Methods inherited from class jmri.util.JmriJFrame
addHelpMenu, componentHidden, componentMoved, componentResized, componentShown, dispose, generateWindowRef, getAllowInFrameServlet, getEscapeKeyAction, getEscapeKeyClosesWindow, getFrame, getFrame, getFrameList, getFrameList, getIndexedProperty, getMaximumSize, getModifiedFlag, getPreferredSize, getProperty, getPropertyNames, getSavePosition, getSaveSize, getScreenDimensions, getWindowFrameRef, getWindowInterface, handleModified, hasIndexedProperty, hasProperty, initComponents, makePrivateWindow, markWindowModified, multipleInstances, pack, setAllowInFrameServlet, setEscapeKeyAction, setEscapeKeyClosesWindow, setFrameLocation, setIndexedProperty, setModifiedFlag, setProperty, setSavePosition, setSaveSize, setShutDownTask, setWindowInterface, show, show, storeValues, undecorate, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
-
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
-
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
-
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, setVisible, show, toBack, toFront
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMinimumSize, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTree
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setMixingCutoutShape, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
Field Detail
-
_triggerOnChangeButton
javax.swing.JRadioButton _triggerOnChangeButton
-
_inActReorder
boolean _inActReorder
-
_inVarReorder
boolean _inVarReorder
-
_nextInOrder
int _nextInOrder
-
_selectLogixPanel
javax.swing.JPanel _selectLogixPanel
-
_selectConditionalPanel
javax.swing.JPanel _selectConditionalPanel
-
_actionTableModel
ConditionalEditFrame.ActionTableModel _actionTableModel
-
_variableTableModel
ConditionalEditFrame.VariableTableModel _variableTableModel
-
_operatorBox
javax.swing.JComboBox<Conditional.AntecedentOperator> _operatorBox
-
_andOperatorBox
javax.swing.JComboBox<java.lang.String> _andOperatorBox
-
_notOperatorBox
javax.swing.JComboBox<java.lang.String> _notOperatorBox
-
_antecedentField
javax.swing.JTextField _antecedentField
-
_antecedentPanel
javax.swing.JPanel _antecedentPanel
-
_newItem
boolean _newItem
-
_editVariableFrame
JmriJFrame _editVariableFrame
-
_variableItemBox
javax.swing.JComboBox<Conditional.ItemType> _variableItemBox
-
_variableStateBox
javax.swing.JComboBox<Conditional.Type> _variableStateBox
-
_variableNameField
javax.swing.JTextField _variableNameField
-
_variableCompareOpBox
javax.swing.JComboBox<java.lang.String> _variableCompareOpBox
-
_variableSignalBox
javax.swing.JComboBox<java.lang.String> _variableSignalBox
-
_variableCompareTypeBox
javax.swing.JComboBox<Conditional.Type> _variableCompareTypeBox
-
_variableData1Field
javax.swing.JTextField _variableData1Field
-
_variableData2Field
javax.swing.JTextField _variableData2Field
-
_reorderVarButton
javax.swing.JButton _reorderVarButton
-
_variableNamePanel
javax.swing.JPanel _variableNamePanel
-
_variableStatePanel
javax.swing.JPanel _variableStatePanel
-
_variableComparePanel
javax.swing.JPanel _variableComparePanel
-
_variableSignalPanel
javax.swing.JPanel _variableSignalPanel
-
_variableData1Panel
javax.swing.JPanel _variableData1Panel
-
_variableData2Panel
javax.swing.JPanel _variableData2Panel
-
_variableComboNamePanel
javax.swing.JPanel _variableComboNamePanel
-
_editActionFrame
JmriJFrame _editActionFrame
-
_actionItemBox
javax.swing.JComboBox<Conditional.ItemType> _actionItemBox
-
_actionTypeBox
javax.swing.JComboBox<Conditional.Action> _actionTypeBox
-
_actionBox
javax.swing.JComboBox<java.lang.String> _actionBox
-
_actionNameField
javax.swing.JTextField _actionNameField
-
_longActionString
javax.swing.JTextField _longActionString
-
_shortActionString
javax.swing.JTextField _shortActionString
-
_actionOptionBox
javax.swing.JComboBox<java.lang.String> _actionOptionBox
-
_actionPanel
javax.swing.JPanel _actionPanel
-
_actionTypePanel
javax.swing.JPanel _actionTypePanel
-
_actionNamePanel
javax.swing.JPanel _actionNamePanel
-
_shortTextPanel
javax.swing.JPanel _shortTextPanel
-
_optionPanel
javax.swing.JPanel _optionPanel
-
_actionComboNamePanel
javax.swing.JPanel _actionComboNamePanel
-
_setPanel
javax.swing.JPanel _setPanel
-
_textPanel
javax.swing.JPanel _textPanel
-
_comboNameBox
NamedBeanComboBox<?> _comboNameBox
-
_curVariable
ConditionalVariable _curVariable
-
_curVariableRowNumber
int _curVariableRowNumber
-
_curVariableItem
Conditional.ItemType _curVariableItem
-
_curAction
ConditionalAction _curAction
-
_curActionRowNumber
int _curActionRowNumber
-
_curActionItem
Conditional.ItemType _curActionItem
-
_selectLogixBox
javax.swing.JComboBox<java.lang.String> _selectLogixBox
-
_selectConditionalBox
javax.swing.JComboBox<java.lang.String> _selectConditionalBox
-
_selectLogixMap
java.util.TreeMap<java.lang.String,java.lang.String> _selectLogixMap
-
_selectConditionalList
java.util.ArrayList<java.lang.String> _selectConditionalList
-
variableSignalTestStateListener
transient java.awt.event.ActionListener variableSignalTestStateListener
-
variableSignalHeadNameListener
transient java.awt.event.ActionListener variableSignalHeadNameListener
-
variableSignalMastNameListener
transient java.awt.event.ActionListener variableSignalMastNameListener
-
selectLogixBoxListener
transient java.awt.event.ActionListener selectLogixBoxListener
-
selectConditionalBoxListener
transient java.awt.event.ActionListener selectConditionalBoxListener
-
sndFileChooser
javax.swing.JFileChooser sndFileChooser
-
scriptFileChooser
ScriptFileChooser scriptFileChooser
-
defaultFileChooser
javax.swing.JFileChooser defaultFileChooser
-
_actionTypeListener
ConditionalEditFrame.ActionTypeListener _actionTypeListener
-
actionSignalHeadNameListener
transient java.awt.event.ActionListener actionSignalHeadNameListener
-
actionSignalMastNameListener
transient java.awt.event.ActionListener actionSignalMastNameListener
-
-
Constructor Detail
-
ConditionalEditFrame
ConditionalEditFrame(java.lang.String title, Conditional conditional, ConditionalList parent)
-
-
Method Detail
-
makeConditionalFrame
void makeConditionalFrame(Conditional conditional)
-
addVariablePressed
void addVariablePressed(java.awt.event.ActionEvent e)
Respond to the Add State Variable Button in the Edit Conditional window.- Parameters:
e
- The event heard
-
checkVariablePressed
void checkVariablePressed(java.awt.event.ActionEvent e)
Respond to the Check State Variable Button in the Edit Conditional window.- Parameters:
e
- the event heard
-
reorderVariablePressed
void reorderVariablePressed(java.awt.event.ActionEvent e)
Respond to the Reorder Variable Button in the Edit Conditional window.- Parameters:
e
- The event heard
-
swapVariables
void swapVariables(int row)
Respond to the First/Next (Delete) Button in the Edit Conditional window.- Parameters:
row
- index of the row to put as next in line (instead of the one that was supposed to be next)
-
variableNegationChanged
void variableNegationChanged(int row, java.lang.String oper)
Respond to the Negation column in the Edit Conditional window.- Parameters:
row
- index of the Conditional to change the setting onoper
- NOT (i18n) as negation of condition
-
variableOperatorChanged
void variableOperatorChanged(int row, java.lang.String oper)
Respond to the Operator column in the Edit Conditional window.- Parameters:
row
- index of the Conditional to change the setting onoper
- AND or OR (i18n) as operand on the list of conditions
-
addActionPressed
void addActionPressed(java.awt.event.ActionEvent e)
Respond to Add action button in the EditConditional window.- Parameters:
e
- The event heard
-
reorderActionPressed
void reorderActionPressed(java.awt.event.ActionEvent e)
Respond to the Reorder Action Button in the Edit Conditional window.- Parameters:
e
- The event heard
-
swapActions
void swapActions(int row)
Respond to the First/Next (Delete) Button in the Edit Conditional window.- Parameters:
row
- index of the row to put as next in line (instead of the one that was supposed to be next)
-
updateConditionalPressed
boolean updateConditionalPressed(java.awt.event.ActionEvent e)
Respond to the Update Conditional Button in the Edit Conditional window.- Overrides:
updateConditionalPressed
in classConditionalFrame
- Parameters:
e
- The event heard- Returns:
- true if updated
-
cancelConditionalPressed
void cancelConditionalPressed()
Respond to the Cancel button in the Edit Conditional frame.Does the cleanup from deleteConditionalPressed, updateConditionalPressed and _editConditionalFrame window closer.
- Overrides:
cancelConditionalPressed
in classConditionalFrame
-
logicTypeChanged
boolean logicTypeChanged(java.awt.event.ActionEvent e)
Respond to a change of Conditional Type in the Edit Conditional pane by showing/hiding the _antecedentPanel when Mixed is selected.- Parameters:
e
- The event heard- Returns:
- false if there is no change in operator
-
helpPressed
void helpPressed(java.awt.event.ActionEvent e)
Respond to Help button press in the Edit Conditional pane.- Parameters:
e
- The event heard
-
makeAntecedent
void makeAntecedent()
Build the antecedent statement.
-
appendToAntecedent
void appendToAntecedent()
Add a R# to the antecedent statement.
-
validateAntecedent
boolean validateAntecedent()
Check the antecedent and logic type.- Returns:
- false if antecedent can't be validated
-
alreadyEditingActionOrVariable
boolean alreadyEditingActionOrVariable()
Check if an editing session is going on.If it is, display a message to user and bring current editing pane to front.
- Returns:
- true if an _editActionFrame or _editVariableFrame exists
-
loadJComboBoxWithHeadAppearances
void loadJComboBoxWithHeadAppearances(javax.swing.JComboBox<java.lang.String> box, java.lang.String signalHeadName)
Fetch valid localized appearances for a given Signal Head.Warn if head is not found.
- Parameters:
box
- the comboBox on the setup pane to fillsignalHeadName
- user or system name of the Signal Head
-
loadJComboBoxWithMastAspects
void loadJComboBoxWithMastAspects(javax.swing.JComboBox<java.lang.String> box, java.lang.String mastName)
Fetch valid aspects for a given Signal Mast.Warn if mast is not found.
- Parameters:
box
- the comboBox on the setup pane to fillmastName
- user or system name of the Signal Mast
-
makeTopPanel
javax.swing.JPanel makeTopPanel(javax.swing.JFrame frame, java.lang.String title, int width, int height)
Create Variable and Action editing pane top part.- Parameters:
frame
- JFrame to add totitle
- property key for border titlewidth
- fixed dimension to useheight
- fixed dimension to use- Returns:
- JPanel containing interface
-
makeButtonPanel
javax.swing.JPanel makeButtonPanel(java.awt.event.ActionListener updateListener, java.awt.event.ActionListener cancelListener, java.awt.event.ActionListener deleteListener)
Create Variable and Action editing pane bottom part.Called from
makeEditVariableWindow(int)
- Parameters:
updateListener
- listener for Update pressedcancelListener
- listener for Cancel presseddeleteListener
- listener for Delete pressed- Returns:
- JPanel containing Update etc. buttons
-
makeEditVariableWindow
void makeEditVariableWindow(int row)
Create and/or initialize the Edit a Variable pane.Note: you can get here via the New Variable button (addVariablePressed) or via an Edit button in the Variable table of the EditConditional window.
- Parameters:
row
- index of item to be edited in _variableList
-
initializeStateVariables
void initializeStateVariables()
Set display to show current state variable (_curVariable) parameters.
-
setVariableNameBox
void setVariableNameBox(Conditional.ItemType itemType)
Update the name combo box selection based on the current contents of the name field.- Parameters:
itemType
- The type of name box to be created.- Since:
- 4.7.3
-
updateVariablePressed
void updateVariablePressed()
Respond to Update Variable button in the Edit Action pane.
-
cancelEditVariablePressed
void cancelEditVariablePressed()
Respond to Cancel action button and window closer of the Edit Variable pane.Also does cleanup of Update and Delete Variable buttons.
-
cleanUpVariable
void cleanUpVariable()
Clean up Update and Delete Variable buttons.
-
deleteVariablePressed
void deleteVariablePressed()
Respond to Delete action button in the Edit Variable window.
-
deleteVariablePressed
void deleteVariablePressed(int row)
Respond to the Delete Button in the State Variable Table of the Edit Conditional window.- Parameters:
row
- index in table of variable to be deleted
-
validateVariable
boolean validateVariable()
Validate Variable data from Edit Variable Window, and transfer it to current action object as appropriate.Messages are sent to the user for any errors found. This routine returns false immediately after finding the first error, even if there might be more errors.
- Returns:
- true if all data checks out OK, otherwise false
-
makeEditActionWindow
void makeEditActionWindow(int row)
Create and/or initialize the Edit Action window.Note: you can get here via the New Action button (addActionPressed) or via an Edit button in the Action table of the EditConditional window.
- Parameters:
row
- index in the table of the Action to be edited
-
loadSelectLogixBox
void loadSelectLogixBox(ConditionalVariable curVariable)
Load the Logix selection box. Set the selection to the current Logix.- Parameters:
curVariable
- Current ConditionalVariable- Since:
- 4.7.4
-
loadSelectConditionalBox
void loadSelectConditionalBox(java.lang.String logixName, ConditionalVariable curVariable)
Load the Conditional selection box. The first row is a prompt.- Parameters:
logixName
- The Logix system name for selecting the owned ConditionalscurVariable
- Current ConditionalVariable- Since:
- 4.7.4
-
initializeActionVariables
void initializeActionVariables()
Set display to show current action (curAction) parameters.
-
actionItemChanged
void actionItemChanged(Conditional.ItemType type)
Respond to a change in an Action Type comboBox on the Edit Conditional Action pane.Set components visible for the selected type.
- Parameters:
type
- index of the newly selected Action type
-
setActionNameBox
void setActionNameBox(Conditional.ItemType itemType)
Update the name combo box selection based on the current contents of the name field. Called byactionItemChanged(Conditional.ItemType)
.- Parameters:
itemType
- The type of name box to be created.- Since:
- 4.7.3
-
updateActionPressed
void updateActionPressed()
Respond to Update Action button in the Edit Action pane.
-
cancelEditActionPressed
void cancelEditActionPressed()
Respond to Cancel action button and window closer of the Edit Action window.Also does cleanup of Update and Delete buttons.
-
cleanUpAction
void cleanUpAction()
Clean up Update and Delete Action buttons.
-
deleteActionPressed
void deleteActionPressed()
Respond to Delete action button in the Edit Action window.
-
deleteActionPressed
void deleteActionPressed(int row)
Respond to Delete action button in an action row of the Edit Conditional pane.- Parameters:
row
- index in table of action to be deleted
-
setFileLocation
void setFileLocation(java.awt.event.ActionEvent e)
Respond to the [...] button in the Edit Action window action section.Ask user to select an audio or python script file on disk.
- Parameters:
e
- the event heard
-
validateAction
boolean validateAction()
Validate Action data from Edit Action Window, and transfer it to current action object as appropriate.Messages are sent to the user for any errors found. This routine returns false immediately after finding an error, even if there might be more errors.
- Returns:
- true if all data checks out OK, otherwise false
-
-