public abstract class MustDialog extends javax.swing.JDialog implements ContextHelp, java.awt.event.WindowListener, ExemptibleManager, AppTextResource
javax.swing.JDialog.AccessibleJDialog
java.awt.Dialog.AccessibleAWTDialog, java.awt.Dialog.ModalExclusionType, java.awt.Dialog.ModalityType
java.awt.Window.AccessibleAWTWindow, java.awt.Window.Type
Modifier and Type | Field and Description |
---|---|
protected boolean |
alreadyMadeInvisible |
static java.awt.Cursor |
defaultCursor |
protected MustDialog |
ownerDialog |
protected java.awt.Frame |
ownerFrame |
protected FrontendResources |
sd |
static boolean |
storedLayout |
static java.awt.Cursor |
waitCursor |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Constructor and Description |
---|
MustDialog() |
MustDialog(java.awt.Frame ownerFrame)
Constructs a new dialog with the specified owner frame.
|
MustDialog(MustDialog ownerDialog)
Constructs a new dialog with the specified owner frame.
|
Modifier and Type | Method and Description |
---|---|
abstract boolean |
acceptsClosingDueToInactivity()
Returns true if frame accepts closing due to inactivity.
|
protected boolean |
adjustSizeToPlausibleValue()
Checks whether the width laid out by user is less then the width resulting by pack(),
resizes the frame in this case to the packed value and returns true.
|
static void |
closeAll()
Closes all dialogs.
|
static void |
closeAllDueToInactivity()
Closes all dialogs that accept closing due to inactivity.
|
void |
closeInstance()
Closes the instance after reminding size and position of the frame as it
was laid-out by the user.
|
void |
free()
Releases external resources.
|
java.lang.String |
getAppResStr(java.lang.String resourceKey)
Returns a text in the corresponding language according to the locale specific resource bundle.
|
MustDialog |
getFrame() |
java.lang.String |
getHelpTarget()
Returns the target of the component's help context
|
java.lang.String |
getHelpTopic()
Returns the topic of the component's help context
|
javax.swing.JRootPane |
getRootPane() |
protected java.lang.String |
getTranslation(java.lang.String resourceKey)
Returns a text in the corresponding language according to the locale
specific resource bundle of the package.
|
boolean |
isLaidOut()
Returns true if the frame has already been laid-out.
|
protected void |
locateInCenter()
Centers the dialog on screen.
|
protected void |
packAndLocateInCenter()
Packs the dialog and centers it.
|
protected void |
packAndLocateInCenterIfNotLaidOut()
Packs the dialog and centers it, if it was't already laid-out.
|
protected void |
packIfNotLaidOut()
Packs the frame if it isn't already laid-out by user.
|
protected void |
popupMessage(java.lang.String messageToKeep) |
static void |
prepareForProgrammaticalClosing()
Prepares dialogs to be programmatically closed.
|
void |
register(Exemptible exemptible)
Registers an object to free its external resources as soon as they are not needed any more.
|
protected void |
setDefaultLocation(int x,
int y)
Sets the location of the frame
|
protected void |
setDefaultSize(java.awt.Dimension LayoutDim)
Constructs a frame using specified dimension(width & height).
|
void |
setHelpContext(java.lang.String helpTopic)
Sets the component's context help.
|
void |
setHelpContext(java.lang.String helpTopic,
java.lang.String helpTarget)
Sets the component's context help.
|
protected void |
setIconImages(java.lang.String[] imageIconNames,
ImageResource imageResource) |
void |
setImageIcon(java.lang.String imageIconName) |
void |
setTitle(java.lang.String title) |
void |
setVisible(boolean b) |
void |
windowActivated(java.awt.event.WindowEvent e) |
void |
windowClosed(java.awt.event.WindowEvent e) |
void |
windowClosing(java.awt.event.WindowEvent e) |
void |
windowDeactivated(java.awt.event.WindowEvent e) |
void |
windowDeiconified(java.awt.event.WindowEvent e) |
void |
windowIconified(java.awt.event.WindowEvent e) |
void |
windowOpened(java.awt.event.WindowEvent e) |
addImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
addNotify, getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setBackground, setModal, setModalityType, setOpacity, setResizable, setShape, setUndecorated, 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, processEvent, processWindowFocusEvent, processWindowStateEvent, 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, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, 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
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, 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, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
public static java.awt.Cursor defaultCursor
public static java.awt.Cursor waitCursor
public static boolean storedLayout
protected java.awt.Frame ownerFrame
protected FrontendResources sd
protected MustDialog ownerDialog
protected boolean alreadyMadeInvisible
public MustDialog()
public MustDialog(java.awt.Frame ownerFrame)
ownerFrame
- the frame which owns the dialogpublic MustDialog(MustDialog ownerDialog)
ownerFrame
- the frame which owns the dialogpublic static void prepareForProgrammaticalClosing()
public static void closeAllDueToInactivity()
prepareForProgrammaticalClosing()
has to be called previously to use this function.public static void closeAll()
prepareForProgrammaticalClosing()
has to be called previously to use this function.protected void setIconImages(java.lang.String[] imageIconNames, ImageResource imageResource)
public void setTitle(java.lang.String title)
setTitle
in class java.awt.Dialog
public javax.swing.JRootPane getRootPane()
getRootPane
in interface javax.swing.RootPaneContainer
getRootPane
in class javax.swing.JDialog
public java.lang.String getAppResStr(java.lang.String resourceKey)
AppTextResource
getAppResStr
in interface AppTextResource
resourceKey
- the key of the resource to retrieveprotected java.lang.String getTranslation(java.lang.String resourceKey)
resourceKey
- the key of the resource to retrieveprotected void setDefaultSize(java.awt.Dimension LayoutDim)
layoutDim
- layout dimension(width & height)protected void setDefaultLocation(int x, int y)
x
- the frame's start location(x)y
- the frame's end location(y)public boolean isLaidOut()
WinContr
protected void packIfNotLaidOut()
protected void locateInCenter()
protected void packAndLocateInCenter()
protected void packAndLocateInCenterIfNotLaidOut()
protected boolean adjustSizeToPlausibleValue()
public MustDialog getFrame()
public void setHelpContext(java.lang.String helpTopic)
helpTopic
- the context help's topichelpTarget
- the context help's targetpublic void setHelpContext(java.lang.String helpTopic, java.lang.String helpTarget)
setHelpContext
in interface ContextHelp
helpTopic
- the context help's topichelpTarget
- the context help's targetpublic java.lang.String getHelpTopic()
getHelpTopic
in interface ContextHelp
public java.lang.String getHelpTarget()
getHelpTarget
in interface ContextHelp
public void register(Exemptible exemptible)
ExemptibleManager
register
in interface ExemptibleManager
exemptible
- the exemptible object to registerpublic void setImageIcon(java.lang.String imageIconName)
protected void popupMessage(java.lang.String messageToKeep)
public void windowClosing(java.awt.event.WindowEvent e)
windowClosing
in interface java.awt.event.WindowListener
public void windowClosed(java.awt.event.WindowEvent e)
windowClosed
in interface java.awt.event.WindowListener
public void windowOpened(java.awt.event.WindowEvent e)
windowOpened
in interface java.awt.event.WindowListener
public void windowActivated(java.awt.event.WindowEvent e)
windowActivated
in interface java.awt.event.WindowListener
public void windowDeactivated(java.awt.event.WindowEvent e)
windowDeactivated
in interface java.awt.event.WindowListener
public void windowIconified(java.awt.event.WindowEvent e)
windowIconified
in interface java.awt.event.WindowListener
public void windowDeiconified(java.awt.event.WindowEvent e)
windowDeiconified
in interface java.awt.event.WindowListener
public abstract boolean acceptsClosingDueToInactivity()
public void free()
ExemptibleManager
free
in interface Exemptible
free
in interface ExemptibleManager
public void closeInstance()
public void setVisible(boolean b)
setVisible
in class java.awt.Dialog
Copyright 1998-2023 Christoph Mueller, Kaerntner Str. 56, D-70469 Stuttgart, Germany, https://www.perpus.de