public class PjWorkshop_Dialog extends PsDialog
The info panel of the workshop is registered as ActionListener of this dialog. Pressing either dialog button will fire an ActionEvent in PsDialog that is then handled by the info panel PjWorkshop_IP. PjWorkshop_IP will call methods corresponding to button events. This mechanism allows that the dialog has a universal use for all workshops in JavaView.
PjWorkshop_IP
,
Serialized FormBUTTON_CANCEL, BUTTON_CLEAR, BUTTON_CLOSE, BUTTON_HIDE, BUTTON_LOAD, BUTTON_OK, BUTTON_RESET, BUTTON_SAVE
Constructor and Description |
---|
PjWorkshop_Dialog()
Constructor of dialog, dialog is not modal.
|
PjWorkshop_Dialog(boolean modal)
Constructor of dialog to show the info panel of a workshop.
|
PjWorkshop_Dialog(java.lang.String title,
boolean modal)
Constructor of dialog to show the info panel of a workshop.
|
Modifier and Type | Method and Description |
---|---|
static PsPanel |
createNotice(java.lang.String text)
Create a panel showing a user notice given as text with line breaks.
|
void |
init()
Initialization method sets the layout manager to BorderLayout.
|
void |
setPanel(PjWorkshop_IP panel)
Assign an inspector panel to be used to fill this dialog.
|
void |
setParent(PsUpdateIf object)
Assign the parent workshop and perform a layout of the dialog.
|
boolean |
update(java.lang.Object event)
Update the class whenever a child has changed.
|
void |
windowClosed(java.awt.event.WindowEvent event)
Catch closing of a dialog by the window manager and
call parent workshop's cancel() method.
|
actionPerformed, addActionListener, componentAdded, componentRemoved, getBottomButtons, getFather, getInsets, getUserAction, instanceOf, keyPressed, keyReleased, keyTyped, removeActionListener, reset, setHeader, setInsetSize, windowActivated, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
addNotify, getAccessibleContext, getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setBackground, setModal, setModalityType, setOpacity, setResizable, setShape, setTitle, setUndecorated, setVisible, show, toBack
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, toFront
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, setLayout, transferFocusDownCycle, update, validate
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, dispatchEvent, enable, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, 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, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName
public PjWorkshop_Dialog()
public PjWorkshop_Dialog(boolean modal)
modal
- true
if dialog is modalpublic PjWorkshop_Dialog(java.lang.String title, boolean modal)
title
- title of the dialogmodal
- true
if dialog is modalpublic void init()
public void setPanel(PjWorkshop_IP panel)
Usually this method is called indirectly when a parent workshop is assigned to this dialog. Then this method is invoked with a new default inspector panel.
If a user wants to register a different inspector panel, then this panel must be created outside and registered using this method. After registration, the workshop registers as usual as parent using setParent().
Currently, this method does not register the info panel of the workshop as action listener in order to receive button events.
panel
- Must be an instance of jvx.project.PjWorkshop_IP.public void setParent(PsUpdateIf object)
Dialog title of the info panel is set as title of the dialog. If the title of the info panel shows the same string as the requested dialog title then the title label is removed from the info panel.
The info panel of the workshop is registered as action listener in order to receive button events.
setParent
in interface PsUpdateIf
setParent
in class PsDialog
object
- Must be an instance of jvx.project.PjWorkshop.PsDialog.getFather()
,
PsDialog.update(Object)
public boolean update(java.lang.Object event)
This method basically returns true if the event is the workshop. More functionality might be added by subclasses of this dialog.
update
in interface PsUpdateIf
update
in class PsDialog
event
- carries a lot of informationPsDialog.getFather()
,
PsDialog.setParent(PsUpdateIf)
public static PsPanel createNotice(java.lang.String text)
text
- text including line breaks "\n".public void windowClosed(java.awt.event.WindowEvent event)
windowClosed
in interface java.awt.event.WindowListener
windowClosed
in class PsDialog
"