Overview | File | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## Class draw2d.EventTarget

    Object
       |
       +--draw2d.EventTarget

class draw2d.EventTarget

Defined in events.js

Constructor Summary
`draw2d.EventTarget ()` Any class that wants to support events should inherit from this.

Method Summary
`void` | `addEventListener(sType , fnListener )` Adds an event listener function to handle the type of event.
`Object` | `dispatchEvent(oEvent )` Causes an event to fire.
`void` | `removeEventListener(sType , fnListener )` Removes an event listener function from handling the type of event.

Constructor Detail

### draw2d.EventTarget

    draw2d.EventTarget()

Any class that wants to support events should inherit from this.

Method Detail

### addEventListener

    void addEventListener(sType , fnListener )

Adds an event listener function to handle the type of event.

Parameters:

`sType` - The type of event to handle (i.e., "mousemove", not "onmousemove").

`fnListener` - The listener function for the event.

### dispatchEvent

    Object dispatchEvent(oEvent )

Causes an event to fire.

Parameters:

`oEvent` - The event object containing information about the event to fire.

Returns:

True if the event should continue, false if not.

### removeEventListener

    void removeEventListener(sType , fnListener )

Removes an event listener function from handling the type of event.

Parameters:

`sType` - The type of event to remove from (i.e., "mousemove", not "onmousemove").

`fnListener` - The listener function to remove.

Overview | File | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Documentation generated by JSDoc on Thu Feb 7 23:45:47 2008