Class JMail.DesktopWindow
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class JMail.DesktopWindow

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Window
                           |
                           +----java.awt.Frame
                                   |
                                   +----JMail.DesktopWindow

public class DesktopWindow
extends Frame
Class to draw the JMail desktop and add the correct folders to the desktop and implement user interaction with the desktop.

Constructor Index

 o DesktopWindow(Applet)
This constructor sets the instance variables and creates the desktop window on the screen.

Method Index

 o action(Event, Object)
This method performs an action on an event and an object.
 o dostuff(Connection, Protocol, String)
This method sets instance variables, redraws the screen and traps exceptions.
 o handleEvent(Event)
This method handles all interaction from the user.
 o mouseDown(Event, int, int)
Method to handle the user clicking an object on the desktop.
 o mouseDrag(Event, int, int)
Method to handle icons being dragged across the desktop.
 o mouseUp(Event, int, int)
Method used to determine where to drop the folder.
 o paint(Graphics)
Paints all of the folders on the desktop.
 o show()
Method to show the super class.

Constructors

 o DesktopWindow
  public DesktopWindow(Applet app_param)
This constructor sets the instance variables and creates the desktop window on the screen.
Parameters:
Applet - app_param used to set instance variable

Methods

 o dostuff
  public void dostuff(Connection c_param,
                      Protocol p_param,
                      String u_param)
This method sets instance variables, redraws the screen and traps exceptions.
Parameters:
Connection - c_param connection instance variable
Protocol - p_param protocol instance variable
String - u_param username instance variable
 o action
  public boolean action(Event evt,
                        Object obj)
This method performs an action on an event and an object.
Parameters:
Event - evt the event which caused the action
Object - obj the object receiving the action
Returns:
false
Overrides:
action in class Component
 o handleEvent
  public synchronized boolean handleEvent(Event e)
This method handles all interaction from the user.
Parameters:
Event - e event that occured on the frame
Returns:
true if successful, false otherwise
Overrides:
handleEvent in class Component
 o show
  public void show()
Method to show the super class.
Overrides:
show in class Window
 o paint
  public void paint(Graphics g)
Paints all of the folders on the desktop.
Parameters:
Graphics - g the object to be painted on
Overrides:
paint in class Component
 o mouseDown
  public boolean mouseDown(Event e,
                           int x,
                           int y)
Method to handle the user clicking an object on the desktop.
Parameters:
Event - e the event generated
int - x the x-coordinate of the mouse position
int - y the y-coordinate of the mouse position
Overrides:
mouseDown in class Component
 o mouseDrag
  public boolean mouseDrag(Event e,
                           int x,
                           int y)
Method to handle icons being dragged across the desktop.
Parameters:
Event - e the event being handled
int - x the x-coordinate of the mouse position
int - y the y-coordinate of the mouse position
Returns:
true if successful, false otherwise
Overrides:
mouseDrag in class Component
 o mouseUp
  public boolean mouseUp(Event e,
                         int x,
                         int y)
Method used to determine where to drop the folder.
Parameters:
Event - e the event being handled
int - x the x-coordinate of the mouse position
int - y the y-coordinate of the mouse position
Returns:
true if successful, false otherwise
Overrides:
mouseUp in class Component

All Packages  Class Hierarchy  This Package  Previous  Next  Index