|
||||||||||
| 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.JMenuBar
|
+--com.ca.directory.jxplorer.MainMenu
| Nested Class Summary | |
class |
MainMenu.myJMenuItem
Extends JMenuItem to add a public string that can be used to store the name of the menu item. |
| Nested classes inherited from class javax.swing.JMenuBar |
javax.swing.JMenuBar.AccessibleJMenuBar |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
static java.lang.String |
fileURLPrefix
|
static java.lang.String |
localDir
|
static java.util.Properties |
myProperties
|
static java.lang.String |
propertyFile
|
| 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 | |
MainMenu(JXplorer jxplorer)
|
|
| Method Summary | |
void |
connect()
|
void |
disconnect()
|
void |
doSearch(java.lang.String name,
java.lang.String filter)
Runs the search. |
protected javax.swing.JScrollPane |
getScrollList(java.lang.Object[] items,
java.lang.String[] toolTips,
javax.swing.JMenu menuType)
Sets up a scrollable list with given items and tooltips. |
void |
goToBookmark(java.lang.String dn,
SmartTree tree)
Tries to display the entry that the user asks for via a bookmark. |
void |
importFile()
|
void |
ldifFullExport(SmartTree activeTree,
boolean usingSearch)
|
void |
ldifSubExport(SmartTree activeTree,
boolean usingSearch)
|
void |
print()
|
void |
setBookmarksEnabled(boolean state)
Enables or disables the bookmark menu items (not the add or edit items - just the actual saved bookmarks). |
protected void |
setCheckBoxMenu(javax.swing.JMenu menu,
java.lang.String[][] menuItems,
java.awt.event.ActionListener listener)
Similar to @setMenu, but for checkboxes. |
void |
setConnected(boolean searchActive)
Called by JX to turn appropriate buttons on. |
void |
setDisconnected()
|
void |
setImageDirs()
Sets the image & icon paths. |
protected void |
setMenu(javax.swing.JMenu menu,
java.lang.String[][] menuItems,
java.awt.event.ActionListener listener)
Utility function; sets up a menu with a bunch of menu items defined as strings, with tooltips and enabled/disabled state. |
protected javax.swing.JMenuItem |
setMenuItem(javax.swing.JMenu menu,
java.awt.event.ActionListener listener,
java.lang.String[] menuItems)
Sets up a menu item with a list of strings |
protected javax.swing.JMenuItem |
setMenuItem(javax.swing.JMenu menu,
javax.swing.JMenuItem item,
java.awt.event.ActionListener listener,
java.lang.String[] menuItems)
Sets up a menu item with a list of strings |
protected void |
setMenuItemState(javax.swing.JMenu menu,
javax.swing.JMenuItem menuItem,
java.lang.String mnemonic,
java.lang.String toolTipText,
boolean enabled)
Takes a menu Item and sets up state information such as the mnemonic, the tool tip text and the enabled/disabled state. |
void |
setSearchEnabled(boolean state)
Enables or disables the search menu items (below the separator). |
protected void |
setUpAdvancedOptions()
Sets up the advanced options dialog (written so that it is set up when the user clicks on the menu item instead of being set up when JX starts. |
protected void |
setupBookmarkMenu(javax.swing.JMenu bookmarkMenu)
Sets up the bookmark menu with menu items and listeners. |
void |
setupEditMenu(javax.swing.JMenu editMenu)
|
protected void |
setupFileMenu(javax.swing.JMenu fileMenu)
|
protected void |
setupHelpMenu(javax.swing.JMenu helpMenu)
|
void |
setupLdifMenu(javax.swing.JMenu ldifMenu)
|
protected void |
setupLookAndFeelMenu(javax.swing.JMenu lookAndFeelMenu)
View menu setup. |
protected void |
setupOptionsMenu(javax.swing.JMenu optionsMenu)
This is a bit evil - it links various options, saved in the dxconfig.txt java properties file, with user menu items. |
protected void |
setupSearchMenu(javax.swing.JMenu searchMenu)
Sets up the search menu with menu items and listeners. |
protected void |
setupSSLMenu(javax.swing.JMenu sslMenu)
|
protected void |
setupToolsMenu(javax.swing.JMenu toolsMenu)
|
void |
showAboutMessage()
Displays an about dialog in the center of JXplorer. |
void |
updateBookmarkMenu()
Calls the set up for the bookmark menu. |
void |
updateSearchMenu()
Calls the set up for the search menu. |
void |
viewOffline()
|
| Methods inherited from class javax.swing.JMenuBar |
add, addNotify, getAccessibleContext, getComponent, getComponentAtIndex, getComponentIndex, getHelpMenu, getMargin, getMenu, getMenuCount, getSelectionModel, getSubElements, getUI, getUIClassID, isBorderPainted, isSelected, menuSelectionChanged, paintBorder, paramString, processKeyBinding, processKeyEvent, processMouseEvent, removeNotify, setBorderPainted, setHelpMenu, setMargin, setSelected, setSelectionModel, setUI, updateUI |
| Methods inherited from class javax.swing.JComponent |
addAncestorListener, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, 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, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, 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, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, 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, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, 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 |
public static java.util.Properties myProperties
public static java.lang.String propertyFile
public static java.lang.String localDir
public static java.lang.String fileURLPrefix
| Constructor Detail |
public MainMenu(JXplorer jxplorer)
| Method Detail |
protected void setupFileMenu(javax.swing.JMenu fileMenu)
public void connect()
public void setConnected(boolean searchActive)
public void disconnect()
public void setDisconnected()
public void print()
public void setupEditMenu(javax.swing.JMenu editMenu)
public void setupLdifMenu(javax.swing.JMenu ldifMenu)
public void ldifFullExport(SmartTree activeTree,
boolean usingSearch)
public void ldifSubExport(SmartTree activeTree,
boolean usingSearch)
public void importFile()
public void viewOffline()
protected void setupSearchMenu(javax.swing.JMenu searchMenu)
searchMenu - the actual search menu that needs to be set up.
public void doSearch(java.lang.String name,
java.lang.String filter)
name - the name of the saved filter.filter - the LDAP filter.public void setSearchEnabled(boolean state)
state - disabled if false, enabled if true.public void updateSearchMenu()
protected javax.swing.JScrollPane getScrollList(java.lang.Object[] items,
java.lang.String[] toolTips,
javax.swing.JMenu menuType)
items - an array of things (usually strings that are added to the list.toolTips - and array of strings used as the tooltips for the items (i.e. tooltip[x] goes with item[x]).menuType - the menu that the listener is reponding to (either the search menu or the bookmark menu).
protected void setupBookmarkMenu(javax.swing.JMenu bookmarkMenu)
bookmarkMenu - the bookmark menu.public void setBookmarksEnabled(boolean state)
state - disabled if false, enabled if true.public void updateBookmarkMenu()
public void goToBookmark(java.lang.String dn,
SmartTree tree)
dn - the dn of the entry that is to be opened.tree - the tree that holds all the entries.protected void setupLookAndFeelMenu(javax.swing.JMenu lookAndFeelMenu)
protected void setupOptionsMenu(javax.swing.JMenu optionsMenu)
protected void setUpAdvancedOptions()
protected void setupSSLMenu(javax.swing.JMenu sslMenu)
protected void setupToolsMenu(javax.swing.JMenu toolsMenu)
protected void setupHelpMenu(javax.swing.JMenu helpMenu)
public void showAboutMessage()
protected void setMenu(javax.swing.JMenu menu,
java.lang.String[][] menuItems,
java.awt.event.ActionListener listener)
... assumes listeners will be created for them elsewhere, and registered here.
menu - the menu object to add this menu item tomenuItems - an array of string arrays defining the various menu items: listener - - a thingumy to monitor the menu item, and do something if it's
checked.
protected javax.swing.JMenuItem setMenuItem(javax.swing.JMenu menu,
java.awt.event.ActionListener listener,
java.lang.String[] menuItems)
menu - the menu to add this menu item tomenuItems - - an array of 4 strings; the name, the hot key, the tip, and a single letter 'E' or 'D' for enabled/disabledlistener - an action listener for this menu item.
protected javax.swing.JMenuItem setMenuItem(javax.swing.JMenu menu,
javax.swing.JMenuItem item,
java.awt.event.ActionListener listener,
java.lang.String[] menuItems)
menu - the menu to add this menu item tomenuItems - - an array of 4 strings; the name, the hot key, the tip, and a single letter 'E' or 'D' for enabled/disabledlistener - an action listener for this menu item.
protected void setCheckBoxMenu(javax.swing.JMenu menu,
java.lang.String[][] menuItems,
java.awt.event.ActionListener listener)
menu - the menu object to add this menu item tomenuItems - an array of string arrays defining the various menu items: listener - - a thingumy to monitor the menu item, and do something if it's
checked.
protected void setMenuItemState(javax.swing.JMenu menu,
javax.swing.JMenuItem menuItem,
java.lang.String mnemonic,
java.lang.String toolTipText,
boolean enabled)
menu - the parent menu.menuItem - the menu item being modifiedmnemonic - the hot key (alt-'key', or prefixed with "ctr"+'key')toolTipText - text displayed when the mouse hovers over componentenabled - whether the menu item is active, or greyed out.public void setImageDirs()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||