|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel com.alee.laf.panel.WebPanel com.alee.managers.popup.WebPopup com.alee.managers.notification.WebNotificationPopup
public class WebNotificationPopup
Custom popup used to display notifications within the application windows.
NotificationManager
,
NotificationStyle
,
NotificationIcon
,
NotificationOption
,
WebPopup
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
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 |
Field Summary | |
---|---|
protected boolean |
accepted
Whether notification is accepted or not. |
protected boolean |
clickToClose
Whether notification can be closed by simple click on popup or not. |
protected boolean |
closeOnOptionSelection
Whether notification popup should be closed when some option is selected by user or not. |
protected java.awt.Component |
content
Notification content. |
protected WebPanel |
contentPanel
|
protected long |
displayTime
Notification display duration. |
protected WebTimer |
displayTimer
Delayed hide timer. |
protected javax.swing.Icon |
icon
Notification icon. |
protected WebImage |
iconImage
Notification visual components. |
protected java.util.List<NotificationListener> |
listeners
Notification popup listeners. |
protected java.util.List<NotificationOption> |
options
Notification options. |
protected WebPanel |
optionsPanel
|
Fields inherited from class com.alee.managers.popup.WebPopup |
---|
animated, closeOnFocusLoss, defaultFocusComponent, fade, fadeFps, fadeStateType, fadeTime, fadeTimer, focusableChilds, focused, focusTracker, lastAncestorListener, lastComponent, lastComponentListener, popupListeners, requestFocusOnShow |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
WebNotificationPopup()
Constructs new notification popup. |
|
WebNotificationPopup(NotificationStyle notificationStyle)
Constructs new notification popup with the specified notification style. |
|
WebNotificationPopup(Painter stylePainter)
Constructs new notification popup with the specified painter. |
|
WebNotificationPopup(PopupStyle popupStyle)
Constructs new notification popup with the specified style. |
Method Summary | |
---|---|
void |
acceptAndHide()
Accepts notification and closes popup. |
void |
addNotificationListener(NotificationListener listener)
Adds directory chooser listener. |
void |
fireAccepted()
Fires when notification accepted and closed. |
void |
fireClosed()
Fires when notification simply closed. |
void |
fireOptionSelected(NotificationOption option)
Fires when notification options is selected. |
java.awt.Component |
getContent()
Returns notification content. |
long |
getDisplayTime()
Returns notification display time. |
javax.swing.Icon |
getIcon()
Returns notification icon. |
java.util.List<NotificationOption> |
getOptions()
Returns notification options list. |
protected void |
initializeNotificationPopup()
Initializes various notification popup settings. |
boolean |
isClickToClose()
Returns whether notification can be closed by simple click on popup or not. |
boolean |
isCloseOnOptionSelection()
Whether notification popup should be closed when some option is selected by user or not. |
void |
removeNotificationListener(NotificationListener listener)
Removes directory chooser listener. |
void |
setClickToClose(boolean clickToClose)
Sets whether notification can be closed by simple click on popup or not. |
void |
setCloseOnOptionSelection(boolean closeOnOptionSelection)
Returns whether notification popup should be closed when some option is selected by user or not. |
void |
setContent(java.awt.Component content)
Sets notification content. |
void |
setContent(java.lang.String content)
Sets notification text content. |
void |
setDisplayTime(long displayTime)
Sets notification display time. |
void |
setIcon(javax.swing.Icon icon)
Sets notification icon. |
void |
setIcon(NotificationIcon iconType)
Sets notification icon type. |
void |
setOptions(java.util.List<NotificationOption> options)
Sets notification options list. |
void |
setOptions(NotificationOption... options)
Sets notification options. |
protected void |
updateContent()
Updates visible notification content. |
protected void |
updateIcon()
Updates visible notification icon. |
protected void |
updateOptions()
Updates visible notification options. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, 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, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.util.List<NotificationListener> listeners
protected boolean clickToClose
protected boolean closeOnOptionSelection
protected long displayTime
protected WebTimer displayTimer
protected boolean accepted
protected javax.swing.Icon icon
protected java.awt.Component content
protected java.util.List<NotificationOption> options
protected WebImage iconImage
protected WebPanel contentPanel
protected WebPanel optionsPanel
Constructor Detail |
---|
public WebNotificationPopup()
public WebNotificationPopup(NotificationStyle notificationStyle)
notificationStyle
- notification stylepublic WebNotificationPopup(PopupStyle popupStyle)
popupStyle
- popup stylepublic WebNotificationPopup(Painter stylePainter)
stylePainter
- popup style painterMethod Detail |
---|
protected void initializeNotificationPopup()
public javax.swing.Icon getIcon()
public void setIcon(javax.swing.Icon icon)
icon
- new notification iconpublic void setIcon(NotificationIcon iconType)
iconType
- new notification icon typeprotected void updateIcon()
public java.awt.Component getContent()
public void setContent(java.awt.Component content)
content
- new notification contentpublic void setContent(java.lang.String content)
content
- new notification text contentprotected void updateContent()
public java.util.List<NotificationOption> getOptions()
public void setOptions(NotificationOption... options)
options
- new notification optionspublic void setOptions(java.util.List<NotificationOption> options)
options
- new notification options listprotected void updateOptions()
public void acceptAndHide()
public boolean isClickToClose()
public void setClickToClose(boolean clickToClose)
clickToClose
- whether notification can be closed by simple click on popup or notpublic boolean isCloseOnOptionSelection()
public void setCloseOnOptionSelection(boolean closeOnOptionSelection)
closeOnOptionSelection
- whether notification popup should be closed when some option is selected by user or notpublic long getDisplayTime()
public void setDisplayTime(long displayTime)
displayTime
- new notification display timepublic void addNotificationListener(NotificationListener listener)
listener
- directory chooser listener to addpublic void removeNotificationListener(NotificationListener listener)
listener
- directory chooser listener to removepublic void fireOptionSelected(NotificationOption option)
public void fireAccepted()
public void fireClosed()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |