ilog.views.appframe.swing
Class IlvPopupMenu

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JPopupMenu
                  extended by ilog.views.appframe.swing.IlvPopupMenu
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, MenuElement

public class IlvPopupMenu
extends JPopupMenu

Pop-up menu that is initialized from the settings.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JPopupMenu
JPopupMenu.AccessibleJPopupMenu, JPopupMenu.Separator
 
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy
 
Field Summary
static String DEFAULT_POPUP_NAME
          Default value of the "name"attribute of the settings element that provides the settings of the pop-up.
static String POPUP_SETTINGS_TYPE
          The type of the root settings element that provides the settings of an IlvPopupMenu instance within the settings.
 
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
IlvPopupMenu()
          Constructs a new IlvPopupMenu.
 
Method Summary
 IlvApplication getApplication()
          Gets the application associated with this menu bar.
 IlvSettings getSettings()
          Gets the settings that the menu bar uses to read its content.
 IlvSettingsElement getSettingsElement()
          Returns the settings element that provides the settings for this pop-up menu.
 String getSettingsName()
          Gets the name that identifies the bar within the settings.
 IlvSettingsQuery getSettingsQuery()
          Returns the query that selects the settings element that defines the content of this toolbar.
 void setApplication(IlvApplication application)
          Sets the application of the pop-up menu.
 void setSettings(IlvSettings settings)
          Sets the settings that the menu bar uses to read its content.
 void setSettingsElement(IlvSettingsElement element)
          Forces the settings of the pop-up menu to be read and written from the specified settings element.
 void setSettingsName(String name)
          Sets the name that identifies the menu bar within the settings of the menu bar, set by invoking the method setSettings(ilog.views.appframe.settings.IlvSettings)
 void setSettingsQuery(IlvSettingsQuery query)
          Sets the query that selects the settings element that defines the content of this toolbar.
 void show(Component invoker, int x, int y)
          Displays the pop-up menu at the position x,y in the coordinate space of the component invoker.
 
Methods inherited from class javax.swing.JPopupMenu
add, add, add, addMenuKeyListener, addPopupMenuListener, addSeparator, createActionChangeListener, createActionComponent, firePopupMenuCanceled, firePopupMenuWillBecomeInvisible, firePopupMenuWillBecomeVisible, getAccessibleContext, getComponent, getComponentAtIndex, getComponentIndex, getDefaultLightWeightPopupEnabled, getInvoker, getLabel, getMargin, getMenuKeyListeners, getPopupMenuListeners, getSelectionModel, getSubElements, getUI, getUIClassID, insert, insert, isBorderPainted, isLightWeightPopupEnabled, isPopupTrigger, isVisible, menuSelectionChanged, pack, paintBorder, paramString, processFocusEvent, processKeyEvent, processKeyEvent, processMouseEvent, remove, removeMenuKeyListener, removePopupMenuListener, setBorderPainted, setDefaultLightWeightPopupEnabled, setInvoker, setLabel, setLightWeightPopupEnabled, setLocation, setPopupSize, setPopupSize, setSelected, setSelectionModel, setUI, setVisible, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, 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, 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, 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, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, 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, 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

DEFAULT_POPUP_NAME

public static final String DEFAULT_POPUP_NAME
Default value of the "name"attribute of the settings element that provides the settings of the pop-up.

See Also:
Constant Field Values

POPUP_SETTINGS_TYPE

public static final String POPUP_SETTINGS_TYPE
The type of the root settings element that provides the settings of an IlvPopupMenu instance within the settings.

See Also:
Constant Field Values
Constructor Detail

IlvPopupMenu

public IlvPopupMenu()
Constructs a new IlvPopupMenu.

Method Detail

show

public void show(Component invoker,
                 int x,
                 int y)
Displays the pop-up menu at the position x,y in the coordinate space of the component invoker.

Overrides:
show in class JPopupMenu
Parameters:
invoker - The component where the pop-up menu is to appear.
x - The x coordinate in the coordinate space of the invoker, at which the pop-up menu is to be displayed.
y - The y coordinate in the coordinate space of the invoker, at which the pop-up menu is to be displayed

getApplication

public IlvApplication getApplication()
Gets the application associated with this menu bar.

Returns:
The application of the pop-up menu.
See Also:
setApplication(ilog.views.appframe.IlvApplication)

setApplication

public void setApplication(IlvApplication application)
Sets the application of the pop-up menu.

Parameters:
application - The new application of the pop-up menu.
See Also:
getApplication()

getSettings

public IlvSettings getSettings()
Gets the settings that the menu bar uses to read its content.

Returns:
The settings of the menu bar.

setSettings

public void setSettings(IlvSettings settings)
Sets the settings that the menu bar uses to read its content.

Parameters:
settings - The new settings of the menu bar.

getSettingsName

public String getSettingsName()
Gets the name that identifies the bar within the settings. If no name is specified using the method setSettingsName(java.lang.String), the name of the default menu bar defined in the Application Framework settings will be returned.

Returns:
The settings name of the menu bar.

setSettingsName

public void setSettingsName(String name)
Sets the name that identifies the menu bar within the settings of the menu bar, set by invoking the method setSettings(ilog.views.appframe.settings.IlvSettings)

Parameters:
name - The new settings name of the menu bar.

setSettingsQuery

public void setSettingsQuery(IlvSettingsQuery query)
Sets the query that selects the settings element that defines the content of this toolbar.

Parameters:
query - The settings query.
See Also:
getSettingsQuery()

getSettingsQuery

public final IlvSettingsQuery getSettingsQuery()
Returns the query that selects the settings element that defines the content of this toolbar.

Returns:
The settings query or null if no query has been specified using the method setSettingsQuery(ilog.views.appframe.settings.IlvSettingsQuery) or if no settings name has been defined using the method setSettingsName(java.lang.String).
See Also:
setSettingsQuery(ilog.views.appframe.settings.IlvSettingsQuery)

setSettingsElement

public void setSettingsElement(IlvSettingsElement element)
Forces the settings of the pop-up menu to be read and written from the specified settings element. This method overrides the settings element that is selected by default within the settings given by the method getSettings() with the query getSettingsQuery().

Parameters:
element - The settings element that provides the settings for the pop-up menu.
See Also:
getSettingsElement()

getSettingsElement

public IlvSettingsElement getSettingsElement()
Returns the settings element that provides the settings for this pop-up menu. If a settings element has been specified with the setSettingsElement(ilog.views.appframe.settings.IlvSettingsElement) method, it will be returned. Otherwise, the settings element is selected from the settings given by the getSettings() method, with the query returned by getSettingsQuery().

Returns:
The settings element or null if no settings element can be found.
See Also:
setSettingsElement(ilog.views.appframe.settings.IlvSettingsElement), getSettingsQuery()


Copyright © 1996-2007 ILOG S.A. All rights reserved.   Documentation homepage.