Class OrandaNav

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----java.applet.Applet
                                   |
                                   +----OrandaNav

public class OrandaNav
extends Applet
implements Runnable

Constructor Index

 o OrandaNav()

Method Index

 o anyLinkHighlighted()
Gets the index of a main link which has been highlighted.
 o drawBackground()
Draws the background of the nav applet and the sub-links.
 o drawLinks()
Draws the links for the nav applet.
 o drawLinkString(Graphics, int)
Calculate the position in which to draw a main link, and draw it.
 o drawSubLinks(Graphics, int)
Draw the second layer of links, highlighting one if it has been flagged by a MouseOver event.
 o getParameters()
Get the parameters.
 o init()
Initialise the fonts, colors, offscreenImage, and create all the links
 o mouseDown(Event, int, int)
If there is a mouse click, see what the last link flagged by MouseOver was and go to the corresponding URL.
 o mouseEnter(Event, int, int)
The same code as mouseMove: it is a "boundary case".
 o mouseExit(Event, int, int)
The same code as mouseMove: it is a "boundary case".
 o mouseMove(Event, int, int)
Whenever the pointer moves in the Graphics area, check if it has moved over a link or sublink, and if so, flag that link or sublink.
 o paint(Graphics)
Copy the offscreenImage to the screen.
 o run()
Keep painting.
 o start()
Start the thread.
 o stop()
Stop the thread.
 o update(Graphics)
Draw the image in memory before copying to the screen.

Constructors

 o OrandaNav
 public OrandaNav()

Methods

 o init
 public void init()
Initialise the fonts, colors, offscreenImage, and create all the links

Overrides:
init in class Applet
 o start
 public void start()
Start the thread.

Overrides:
start in class Applet
 o stop
 public void stop()
Stop the thread.

Overrides:
stop in class Applet
 o run
 public void run()
Keep painting.

 o paint
 public void paint(Graphics g)
Copy the offscreenImage to the screen.

Overrides:
paint in class Container
 o update
 public void update(Graphics g)
Draw the image in memory before copying to the screen.

Overrides:
update in class Component
 o drawBackground
 public void drawBackground()
Draws the background of the nav applet and the sub-links.

 o anyLinkHighlighted
 public int anyLinkHighlighted()
Gets the index of a main link which has been highlighted.

 o drawLinks
 public void drawLinks()
Draws the links for the nav applet.

 o drawLinkString
 public void drawLinkString(Graphics gr,
                            int i)
Calculate the position in which to draw a main link, and draw it.

 o drawSubLinks
 public void drawSubLinks(Graphics gr,
                          int i)
Draw the second layer of links, highlighting one if it has been flagged by a MouseOver event.

 o mouseDown
 public boolean mouseDown(Event evt,
                          int x,
                          int y)
If there is a mouse click, see what the last link flagged by MouseOver was and go to the corresponding URL.

Overrides:
mouseDown in class Component
 o mouseMove
 public boolean mouseMove(Event evt,
                          int x,
                          int y)
Whenever the pointer moves in the Graphics area, check if it has moved over a link or sublink, and if so, flag that link or sublink.

Overrides:
mouseMove in class Component
 o mouseEnter
 public boolean mouseEnter(Event evt,
                           int x,
                           int y)
The same code as mouseMove: it is a "boundary case".

Overrides:
mouseEnter in class Component
 o mouseExit
 public boolean mouseExit(Event evt,
                          int x,
                          int y)
The same code as mouseMove: it is a "boundary case".

Overrides:
mouseExit in class Component
 o getParameters
 public void getParameters()
Get the parameters.