com.lizardtech.djvubean.menu
Class DjVuMenu

java.lang.Object
  extended by java.awt.MenuComponent
      extended by java.awt.MenuItem
          extended by java.awt.Menu
              extended by java.awt.PopupMenu
                  extended by com.lizardtech.djvubean.menu.DjVuMenu
All Implemented Interfaces:
java.awt.event.MouseListener, java.awt.MenuContainer, java.beans.PropertyChangeListener, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible

public class DjVuMenu
extends java.awt.PopupMenu
implements java.awt.event.MouseListener, java.beans.PropertyChangeListener

This class implements a pop-up menu the user may use to navigate the DjVu Document.

Version:
$Revision: 1.6 $
Author:
Bill C. Riemers
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.awt.PopupMenu
java.awt.PopupMenu.AccessibleAWTPopupMenu
 
Nested classes/interfaces inherited from class java.awt.Menu
java.awt.Menu.AccessibleAWTMenu
 
Nested classes/interfaces inherited from class java.awt.MenuItem
java.awt.MenuItem.AccessibleAWTMenuItem
 
Nested classes/interfaces inherited from class java.awt.MenuComponent
java.awt.MenuComponent.AccessibleAWTMenuComponent
 
Constructor Summary
DjVuMenu(DjVuBean bean)
          Creates a new MenuBar object.
 
Method Summary
 java.awt.MenuItem getAboutMenuItem()
          Query and/or create the about menu item.
 java.lang.String getAboutURL()
          Query the about url.
 DjVuBean getDjVuBean()
          Query the DjVuBean this DjVuMenu has been associated with.
 java.awt.MenuItem getFindMenuItem()
          Query and/or create the text search menu item.
 java.awt.MenuItem getHelpMenuItem()
          Query and/or create the help menu item.
 java.lang.String getHelpURL()
          Query the help url
 java.lang.String getNavPane()
          Query the navpane setting.
 java.awt.Menu getNavPaneMenu()
          Query and/or create the nav pane menu.
 java.awt.Menu getZoomMenu()
          Query and/or create the zoom menu.
 void init()
          Called to initialize or reinitialize the menu layout.
 void mouseClicked(java.awt.event.MouseEvent event)
          Called when the mouse is clicked.
 void mouseEntered(java.awt.event.MouseEvent event)
          Called when the mouse enters the DjVuBean.
 void mouseExited(java.awt.event.MouseEvent e)
          Called when the mouse exits the DjVuBean.
 void mousePressed(java.awt.event.MouseEvent e)
          Called when the mouse button is pressed.
 void mouseReleased(java.awt.event.MouseEvent e)
          Called when the mouse button is released.
 void propertyChange(java.beans.PropertyChangeEvent event)
          Called with a DjVuBean property has changed.
 
Methods inherited from class java.awt.PopupMenu
addNotify, getAccessibleContext, show
 
Methods inherited from class java.awt.Menu
add, add, addSeparator, countItems, getItem, getItemCount, insert, insert, insertSeparator, isTearOff, paramString, remove, remove, removeAll, removeNotify
 
Methods inherited from class java.awt.MenuItem
addActionListener, deleteShortcut, disable, disableEvents, enable, enable, enableEvents, getActionCommand, getActionListeners, getLabel, getListeners, getShortcut, isEnabled, processActionEvent, processEvent, removeActionListener, setActionCommand, setEnabled, setLabel, setShortcut
 
Methods inherited from class java.awt.MenuComponent
dispatchEvent, getFont, getName, getParent, getPeer, getTreeLock, postEvent, setFont, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Constructor Detail

DjVuMenu

public DjVuMenu(DjVuBean bean)
Creates a new MenuBar object.

Parameters:
bean - DjVuBean to add this menu to.
Method Detail

getAboutMenuItem

public java.awt.MenuItem getAboutMenuItem()
Query and/or create the about menu item.

Returns:
about menu item.

getAboutURL

public java.lang.String getAboutURL()
Query the about url.

Returns:
about url

getDjVuBean

public DjVuBean getDjVuBean()
Query the DjVuBean this DjVuMenu has been associated with.

Returns:
the parent cast as a DjVuBean.

getFindMenuItem

public java.awt.MenuItem getFindMenuItem()
Query and/or create the text search menu item.

Returns:
the text search menu item.

getHelpMenuItem

public java.awt.MenuItem getHelpMenuItem()
Query and/or create the help menu item.

Returns:
the help menu item.

getHelpURL

public java.lang.String getHelpURL()
Query the help url

Returns:
the help url.

getNavPane

public java.lang.String getNavPane()
Query the navpane setting.

Returns:
the navpane setting.

getNavPaneMenu

public java.awt.Menu getNavPaneMenu()
Query and/or create the nav pane menu.

Returns:
the nav pane menu.

getZoomMenu

public java.awt.Menu getZoomMenu()
Query and/or create the zoom menu.

Returns:
the zoom menu.

init

public void init()
Called to initialize or reinitialize the menu layout.


mouseClicked

public void mouseClicked(java.awt.event.MouseEvent event)
Called when the mouse is clicked. If a right mouse click or a control key is pressed, then the menu will be displayed.

Specified by:
mouseClicked in interface java.awt.event.MouseListener
Parameters:
event - indicating mouse action.

mouseEntered

public void mouseEntered(java.awt.event.MouseEvent event)
Called when the mouse enters the DjVuBean.

Specified by:
mouseEntered in interface java.awt.event.MouseListener
Parameters:
event - indicating mouse action.

mouseExited

public void mouseExited(java.awt.event.MouseEvent e)
Called when the mouse exits the DjVuBean.

Specified by:
mouseExited in interface java.awt.event.MouseListener
Parameters:
e - indicating mouse action.

mousePressed

public void mousePressed(java.awt.event.MouseEvent e)
Called when the mouse button is pressed.

Specified by:
mousePressed in interface java.awt.event.MouseListener
Parameters:
e - indicating mouse action.

mouseReleased

public void mouseReleased(java.awt.event.MouseEvent e)
Called when the mouse button is released.

Specified by:
mouseReleased in interface java.awt.event.MouseListener
Parameters:
e - indicating mouse action.

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent event)
Called with a DjVuBean property has changed.

Specified by:
propertyChange in interface java.beans.PropertyChangeListener
Parameters:
event - indicating the property change.