com.droplets.api.event
Class ClickEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--com.droplets.api.event.ClickEvent
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
TreeClickEvent

public class ClickEvent
extends java.util.EventObject

Event fired when a click or double-click occurs on a component.

See Also:
Serialized Form

Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ClickEvent(Component source)
          Constructs a new ClickEvent
ClickEvent(Component source, boolean isDoubleClick)
          Construct a new ClickEvent with double click flag.
 
Method Summary
 boolean getIsDoubleClick()
           
 Component getSourceComponent()
          Type-safe method to return the source object of this event, since we know it's a Component.
 boolean isTreeClickEvent()
          Method to determine if this ClickEvent is actually a TreeClickEvent.
 void setIsDoubleClick(boolean isDoubleClick)
          Sets whether or not the event pertains to a double-click.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClickEvent

public ClickEvent(Component source)
Constructs a new ClickEvent
Parameters:
source - the component that was clicked

ClickEvent

public ClickEvent(Component source,
                  boolean isDoubleClick)
Construct a new ClickEvent with double click flag.
Method Detail

getSourceComponent

public Component getSourceComponent()
Type-safe method to return the source object of this event, since we know it's a Component.
Returns:
the component that was clicked

getIsDoubleClick

public boolean getIsDoubleClick()
Returns:
true if the event pertains to a double-click

setIsDoubleClick

public void setIsDoubleClick(boolean isDoubleClick)
Sets whether or not the event pertains to a double-click.

isTreeClickEvent

public boolean isTreeClickEvent()
Method to determine if this ClickEvent is actually a TreeClickEvent.


Copyright © Droplets, 2001. All Rights Reserved.